Commit acda3dd
fix(main): report transition-assertion failures on the inbound link (#362)
CheckTransitionInvariants stores its failure metadata on the *inbound
link* (node.Inbound[0].FailedInvariants) rather than on the node's
Process.FailedInvariants — see processor.go where the write happens.
The failure-reporting branch in modelCheckSingleSpec only looked at
the Process field, with these wrong consequences:
- Simulation mode: a transition-assertion failure fell through to
"FAILED: Model checker failed. Deadlock/stuttering detected", which
is misleading (deadlock_detection: false in the spec confirms it
was not a deadlock).
- Model-checking mode: nothing about the failure was printed at all,
only the raw trace dump from dumpFailedNode.
Now: if the node has no Process.FailedInvariants, check the inbound
link. Print "Transition Invariant: <name>" if found. Add a generic
"Model checker failed (no failed-invariant metadata...)" fallback for
model-checking mode so silence never happens.
Reproducer: a spec with a `transition assertion` that the model
checker finds violating — previously misreported. Confirmed both
modes now print the assertion name (TerminalStatesRemainTerminal in
the test spec).
Co-authored-by: jayaprabhakar <jayaprabhakar@gmail.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent c8b74c1 commit acda3dd
1 file changed
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
870 | 870 | | |
871 | 871 | | |
872 | 872 | | |
| 873 | + | |
| 874 | + | |
| 875 | + | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
| 879 | + | |
873 | 880 | | |
874 | 881 | | |
| 882 | + | |
| 883 | + | |
875 | 884 | | |
876 | 885 | | |
| 886 | + | |
| 887 | + | |
877 | 888 | | |
878 | 889 | | |
879 | 890 | | |
| |||
0 commit comments