inspect-demo
A terminal demo of machina-inspect. demo.ts runs inspect() against FSM configs with intentional structural bugs and prints the findings for each one. It is the quickest way to see what each finding type looks like in practice.
Running
Section titled “Running”What it prints
Section titled “What it prints”The demo walks through its scenarios in numbered sections:
- A clean traffic-light config, with an empty findings array
- An unreachable state, where
brokenhas an outbound edge and lacks an inbound one - An unconditional
_onEnterloop between two states - A conditional
_onEnterbounce, which the loop check skips on purpose - Function handlers plus an unreachable state
- A live
Fsminstance passed toinspect() - A live
BehavioralFsminstance - The graph IR from
buildStateGraph() - A child FSM with an unreachable state
Sections 3 and 4 pair up to show how the loop check decides. An unconditional cycle is a bug, and a conditional bounce is an intentional pattern the check skips.