≈ the.bay.news

Simplicity: the cap is the easy half

programming.dev
Simplicity: the cap is the easy half
Linter caps are easy. Max parameters at three, complexity limits, a hard cap on function length. Those are mechanical and they work, but they don’t touch the move that actually costs you. Generating a four-parameter helper from one example is easy. The agent does it in seconds, the diff looks tidy, and no cap fires because four is under the limit and the function is short. The tell is in the sentence I have to say in review: what requirement does this serve? Most of the time the honest answer is none yet. A parameter added for the next time it’s needed, a flag so one caller can opt out of half a helper, a config option in case someone asks. Each one is rational on its own and there is no moment where anyone decides to make the codebase harder to open. It compounds. The sub-discipline I find hardest is rejecting the easy generation. The agent will produce the general version because the general version is what the shape suggests, and accepting it feels like good taste rather than the opposite. The version I want instead serves the requirement in front of me. A note so the next person can generalise when the requirement arrives. The 1973 line still holds. Simplicity is a necessary condition. The cap only enforces the part of it you can count. https://prickles.org/tenet/simplicity/F4 [https://prickles.org/tenet/simplicity/F4]

0 comments

Sign in to join the discussion — your thebay.events account works here.

No comments yet.