Build1 distinct publisher3 min readUpdated
An illegal transition throws an exception you can grep for. An undefined one returns success and quietly drifts from the order history your support team reads.
The Engineer · Build desk

Compiled by The EngineerSomething wrong?How this is made
A post on dev.to makes a narrow and correct point about state machines: the defect that freezes a service is usually not a wrong transition but one nobody defined [2]. The wrong transition at least raises an exception you can find in a log, while the undefined one often falls through to a default branch that silently returns the current state and reports success [2].
That is the failure mode the standard test cannot see, because the standard test walks the path you already believe in: pending to paid to shipped to delivered [1]. It passes, and it tells you almost nothing [1].
The post argues the problem gets worse when a model drafted the machine. A model is good at producing the transitions implied by a natural-language description, but it rarely asks what should happen when a cancel event arrives after the order has already shipped, so it leaves the grid incomplete and the code patches the gap with a broad else clause [3]. The proposed contract is simple enough to hold in your head during review: every combination of state and event needs an explicit owner, and a rejection counts as an owner [4].
The worked example is where this gets useful, mostly because of what it accidentally demonstrates. The sample machine defines seven states and seven events, including an update_address event [6], with eight explicit transitions in the table [5]. Seven by seven is forty-nine cells [10], so forty-one of them are undefined before anyone touches the code [11]. None of the undefined pairs the post names, such as shipped with cancel, delivered with cancel, or refunded with pay, is a broken state, and none crashes on clean input [7]. They are simply absent from the machine's vocabulary [7].
The harness then hard-codes a rejection set and asserts that every cell is either a transition or a rejection, raising an AssertionError naming the unhandled cell otherwise [9]. That rejection set contains seven pairs [8]. Forty-one minus seven leaves thirty-four cells still unhandled, which means the example harness, run as written, fails on its own machine [12]. Read that as the article's real argument rather than a bug: enumerating the grid is the easy part, and classifying it is the work.
Look at update_address in particular. It appears in the event list but in none of the eight transitions, so it occupies seven cells, exactly one of which the rejection set covers [13]. An event that moves nothing anywhere is either dead vocabulary or a silent no-op in six states, and only the grid surfaces the question.
One thing to discount: the post discloses it was prepared as part of MonkeyCode's product outreach, and recommends free model access and a free server so you can run the whole cross-product instead of sampling happy paths [14]. Forty-nine dictionary lookups do not need free compute [10]. The transferable instruction is the prompt shape: ask the model to list the events each state must reject, not only the events that move the machine forward [15], and if it says a cancel on a shipped order leaves the state unchanged, write that as an assertion instead of letting a default branch imply it [16].
What to watch in review: the count of covered cells, not the diagram. Ask for the number of state-event pairs with an explicit owner against the total, treat any model-generated rejection list as a hypothesis with the coverage gap attached [12], and check whether your own default branch returns the current state on input the machine never agreed to accept [2].
Follow any of these and your For You feed starts watching them — no settings page required.
Ranked by verification strength, evidence, and original report placement.
The article's stated contract is that every combination of state and event must have an explicit owner, even when the owner is a rejection.
The sample transition table contains eight explicit entries: (pending, pay) to paid, (pending, cancel) to cancelled, (paid, ship) to shipped, (paid, cancel) to cancelled, (shipped, deliver) to delivered, (delivered, return) to returned, (cancelled, refund) to refunded, and (returned, refund) to refunded.
The sample declares seven states (pending, paid, shipped, delivered, cancelled, returned, refunded) and seven events (pay, cancel, ship, deliver, return, refund, update_address).
The article discloses it was prepared as part of MonkeyCode's product outreach, and says that with MonkeyCode's free model access and free server option you can afford to run the entire cross-product instead of sampling a few happy paths.
The article advises asking the model to list the events that must be rejected for each state, not just the events that move the machine forward, and turning those guesses into a table the test can verify.
The article says a rejection is also a decision: if the model says a cancel on a shipped order should leave the state unchanged, that must be written as an assertion rather than left to a default branch.
Evidence-backed comparisons of source perspectives and observed adoption signals. Read the methodology
Which Builder, Operator, and Investor concerns the observed source mix emphasized—not a truth score.
Evidence, demonstrated adoption, hype gap, incentives, and confidence are assessed independently, each on its own current evidence. How these are measured.
Self-verifying code, unverified claims
The mechanical core is fully inspectable: the transition table, states/events lists, enumeration loop and assertion harness are printed, so the grid arithmetic can be checked without leaving the source. But the persuasive claims - that undefined cells silently report success in production and that model-drafted machines routinely leave the grid incomplete - carry no data, and the published harness contradicts its own framing by leaving 34 of 49 cells unhandled. One sponsored publisher, no corroboration.
No adoption signal
The supplied source reports no release, deployment, benchmark, usage disclosure, or pricing change. The technique is presented as a suggested review practice and MonkeyCode's free tiers are mentioned only as a pitch, with no users, volumes, or integrations named, so no adoption level can be measured without inventing facts.
Overstated by its own listing
Positive gap: the article frames the harness as a cheap, repeatable verification that no cell is left to an implicit default, and generalizes from there to production payment systems drifting from order history, yet the published rejection table covers only 7 of 41 undefined cells so the check as shipped fails on the sample it demonstrates. The gap is moderate rather than extreme because the article explicitly concedes real limits - multiplicative table growth and the fact that a complete grid can still route a refund to the wrong ledger.
Disclosed vendor outreach
The article states outright that it was prepared as part of MonkeyCode's product outreach, and the recommended practice - enumerate and classify the entire cross-product rather than sample happy paths - maps directly onto the sponsor's free model access and free server option, which are invoked twice as the enabling resources. The disclosure is explicit and early, which is to its credit, but the commercial alignment between advice and offering is strong.
Checkable mechanics, thin sourcing
Confidence is moderate-low. What can be verified is verified with certainty because the code is printed, so the structural and derived claims are firm. Everything beyond the listing - failure prevalence, model behaviour, any adoption - depends on a single sponsored publisher with no corroboration, and one adoption dimension is unmeasurable, so the overall read cannot be held strongly.
build
Your 90% Cache Hit Ratio Is a Lagging Indicator. Alert on Cold Misses Per Key1 distinct publisher
build
An AI test suite hit 94% coverage and missed the one branch that mattered1 distinct publisher
build
Stop timing your GraphQL tests and start counting loader calls1 distinct publisher
build
Your REPL Is Not A Container: Put Free-Variable Checks In CI Before Generated Code Ships1 distinct publisher
Distinct publishers with included, body-backed reporting in this cluster.
dev.to
1 article · August 16, 2026