pi-t3-pstack 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +23 -0
- package/index.ts +87 -0
- package/package.json +62 -4
- package/pstack/.claude-plugin/icon.png +0 -0
- package/pstack/.claude-plugin/plugin.json +35 -0
- package/pstack/.codex-plugin/plugin.json +50 -0
- package/pstack/README.md +26 -0
- package/pstack/agents/comment-sicko.md +32 -0
- package/pstack/agents/poteto-agent.md +8 -0
- package/pstack/agents/thermo-nuclear-code-quality-review-subagent.md +23 -0
- package/pstack/agents/thermo-nuclear-review-subagent.md +28 -0
- package/pstack/assets/pstack-icon.png +0 -0
- package/pstack/assets/pstack-icon.prompt.txt +8 -0
- package/pstack/hooks/codex-hooks.json +16 -0
- package/pstack/hooks/hooks.json +15 -0
- package/pstack/hooks/session-start-context.md +17 -0
- package/pstack/hooks/session-start.ps1 +33 -0
- package/pstack/hooks/session-start.sh +34 -0
- package/pstack/models.json +261 -0
- package/pstack/skills/architect/SKILL.md +85 -0
- package/pstack/skills/architect/references/design-red-flags.md +57 -0
- package/pstack/skills/architect/references/rationale-template.md +35 -0
- package/pstack/skills/architect/references/runner-prompt.md +20 -0
- package/pstack/skills/arena/SKILL.md +55 -0
- package/pstack/skills/automate-me/SKILL.md +104 -0
- package/pstack/skills/benchmark-checklist/SKILL.md +39 -0
- package/pstack/skills/blast-radius/SKILL.md +50 -0
- package/pstack/skills/bro/SKILL.md +7 -0
- package/pstack/skills/correct/SKILL.md +32 -0
- package/pstack/skills/create-formal-verification-skill/SKILL.md +43 -0
- package/pstack/skills/create-verification-skill/SKILL.md +44 -0
- package/pstack/skills/create-verification-skill/references/feature-map-example/README.md +47 -0
- package/pstack/skills/create-verification-skill/references/feature-map-example/create-note.md +39 -0
- package/pstack/skills/create-verification-skill/references/feature-map-example/search.md +45 -0
- package/pstack/skills/deslop/SKILL.md +22 -0
- package/pstack/skills/figure-it-out/SKILL.md +52 -0
- package/pstack/skills/fix-ci/SKILL.md +29 -0
- package/pstack/skills/fix-merge-conflicts/SKILL.md +32 -0
- package/pstack/skills/get-pr-comments/SKILL.md +23 -0
- package/pstack/skills/how/SKILL.md +43 -0
- package/pstack/skills/how/references/explainer-prompt.md +55 -0
- package/pstack/skills/how/references/explorer-prompt.md +35 -0
- package/pstack/skills/in-your-own-words/SKILL.md +7 -0
- package/pstack/skills/interrogate/SKILL.md +37 -0
- package/pstack/skills/ketchup/SKILL.md +43 -0
- package/pstack/skills/ketchup-video/SKILL.md +29 -0
- package/pstack/skills/maintain-formal-verification-skill/SKILL.md +58 -0
- package/pstack/skills/maintain-verification-skill/SKILL.md +39 -0
- package/pstack/skills/make-pr-easy-to-review/SKILL.md +59 -0
- package/pstack/skills/no-comments/SKILL.md +24 -0
- package/pstack/skills/poteto-help/SKILL.md +162 -0
- package/pstack/skills/poteto-help/references/prompting.md +51 -0
- package/pstack/skills/poteto-help/references/recipes.md +51 -0
- package/pstack/skills/poteto-mode/SKILL.md +186 -0
- package/pstack/skills/poteto-mode/brief.md +70 -0
- package/pstack/skills/poteto-mode/playbooks/authoring-a-skill.md +12 -0
- package/pstack/skills/poteto-mode/playbooks/autonomous-run.md +13 -0
- package/pstack/skills/poteto-mode/playbooks/autopilot-full.md +25 -0
- package/pstack/skills/poteto-mode/playbooks/autopilot-stack.md +8 -0
- package/pstack/skills/poteto-mode/playbooks/babysit.md +23 -0
- package/pstack/skills/poteto-mode/playbooks/bug-fix.md +15 -0
- package/pstack/skills/poteto-mode/playbooks/eval.md +25 -0
- package/pstack/skills/poteto-mode/playbooks/feature.md +21 -0
- package/pstack/skills/poteto-mode/playbooks/hillclimb.md +21 -0
- package/pstack/skills/poteto-mode/playbooks/investigation.md +14 -0
- package/pstack/skills/poteto-mode/playbooks/multi-phase-plan.md +155 -0
- package/pstack/skills/poteto-mode/playbooks/opening-a-pr.md +34 -0
- package/pstack/skills/poteto-mode/playbooks/orchestrate.md +25 -0
- package/pstack/skills/poteto-mode/playbooks/pause-safely.md +10 -0
- package/pstack/skills/poteto-mode/playbooks/perf-issue.md +25 -0
- package/pstack/skills/poteto-mode/playbooks/prototype.md +14 -0
- package/pstack/skills/poteto-mode/playbooks/refactoring.md +16 -0
- package/pstack/skills/poteto-mode/playbooks/runtime-forensics.md +11 -0
- package/pstack/skills/poteto-mode/playbooks/session-pickup.md +11 -0
- package/pstack/skills/poteto-mode/playbooks/shipping.md +12 -0
- package/pstack/skills/poteto-mode/playbooks/trace-forensics.md +14 -0
- package/pstack/skills/poteto-mode/playbooks/visual-parity.md +11 -0
- package/pstack/skills/poteto-mode/playbooks/worktree-cleanup.md +12 -0
- package/pstack/skills/poteto-mode/references/bugbot-triage.md +142 -0
- package/pstack/skills/poteto-mode/references/licenses/LICENSE +23 -0
- package/pstack/skills/poteto-mode/references/licenses/LICENSE-cursor-team-kit +21 -0
- package/pstack/skills/poteto-mode/references/licenses/LICENSE-thermos +21 -0
- package/pstack/skills/poteto-mode/references/licenses/NOTICE.md +14 -0
- package/pstack/skills/poteto-mode/scripts/.prettierrc.json +3 -0
- package/pstack/skills/poteto-mode/scripts/bootstrap.ts +62 -0
- package/pstack/skills/poteto-mode/scripts/bun.lock +67 -0
- package/pstack/skills/poteto-mode/scripts/check-plan.mjs +205 -0
- package/pstack/skills/poteto-mode/scripts/check-plan.test.ts +110 -0
- package/pstack/skills/poteto-mode/scripts/package.json +12 -0
- package/pstack/skills/poteto-mode/scripts/resolve-codex-transcript +4 -0
- package/pstack/skills/poteto-mode/scripts/resolve-codex-transcript.ts +314 -0
- package/pstack/skills/poteto-mode/scripts/test-utils/node-test.ts +204 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/cli.test.ts +225 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/cli.ts +231 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/fakes.test-helper.ts +142 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/github.test.ts +498 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/github.ts +760 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/policy.test.ts +483 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/policy.ts +1023 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/render.ts +188 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/settle.test.ts +552 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/settle.ts +406 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/tsconfig.json +18 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/types.compile.ts +93 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/types.ts +444 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/verdicts.test.ts +796 -0
- package/pstack/skills/poteto-mode/scripts/watch-pr/watch-pr +3 -0
- package/pstack/skills/poteto-mode/scripts/worktree-audit.sh +170 -0
- package/pstack/skills/principle-attack-the-premise/SKILL.md +21 -0
- package/pstack/skills/principle-boundary-discipline/SKILL.md +34 -0
- package/pstack/skills/principle-build-the-lever/SKILL.md +23 -0
- package/pstack/skills/principle-encode-lessons-in-structure/SKILL.md +11 -0
- package/pstack/skills/principle-exhaust-the-design-space/SKILL.md +9 -0
- package/pstack/skills/principle-experience-first/SKILL.md +19 -0
- package/pstack/skills/principle-explain-the-number/SKILL.md +18 -0
- package/pstack/skills/principle-fix-root-causes/SKILL.md +21 -0
- package/pstack/skills/principle-foundational-thinking/SKILL.md +21 -0
- package/pstack/skills/principle-guard-the-context-window/SKILL.md +12 -0
- package/pstack/skills/principle-laziness-protocol/SKILL.md +10 -0
- package/pstack/skills/principle-make-operations-idempotent/SKILL.md +22 -0
- package/pstack/skills/principle-migrate-callers-then-delete-legacy-apis/SKILL.md +14 -0
- package/pstack/skills/principle-minimize-reader-load/SKILL.md +18 -0
- package/pstack/skills/principle-model-the-domain/SKILL.md +24 -0
- package/pstack/skills/principle-never-block-on-the-human/SKILL.md +15 -0
- package/pstack/skills/principle-outcome-oriented-execution/SKILL.md +21 -0
- package/pstack/skills/principle-prove-it-works/SKILL.md +22 -0
- package/pstack/skills/principle-redesign-from-first-principles/SKILL.md +16 -0
- package/pstack/skills/principle-separate-before-serializing-shared-state/SKILL.md +16 -0
- package/pstack/skills/principle-sequence-verifiable-units/SKILL.md +17 -0
- package/pstack/skills/principle-subtract-before-you-add/SKILL.md +18 -0
- package/pstack/skills/principle-test-behavior-not-implementation/SKILL.md +20 -0
- package/pstack/skills/principle-type-system-discipline/SKILL.md +13 -0
- package/pstack/skills/recall/SKILL.md +35 -0
- package/pstack/skills/reflect/SKILL.md +86 -0
- package/pstack/skills/reflect/references/divergent-reviewer.md +38 -0
- package/pstack/skills/reflect/references/judgment-reviewer.md +37 -0
- package/pstack/skills/reflect/references/synthesizer.md +56 -0
- package/pstack/skills/reflect/references/tooling-reviewer.md +48 -0
- package/pstack/skills/reflect/scripts/find-transcript.mjs +245 -0
- package/pstack/skills/setup-pstack/SKILL.md +77 -0
- package/pstack/skills/setup-pstack/scripts/read-sheet.sh +14 -0
- package/pstack/skills/setup-pstack/scripts/t3-sheet.mjs +169 -0
- package/pstack/skills/sharpen/SKILL.md +16 -0
- package/pstack/skills/show-me-your-work/SKILL.md +82 -0
- package/pstack/skills/show-me-your-work/references/decision-log-template.tsv +1 -0
- package/pstack/skills/show-me-your-work/scripts/log.sh +42 -0
- package/pstack/skills/statechart/SKILL.md +82 -0
- package/pstack/skills/statechart/references/render.md +93 -0
- package/pstack/skills/statechart/scripts/backends/cfg.ts +33 -0
- package/pstack/skills/statechart/scripts/backends/mermaid.ts +201 -0
- package/pstack/skills/statechart/scripts/backends/plain-text.ts +72 -0
- package/pstack/skills/statechart/scripts/backends/report.ts +177 -0
- package/pstack/skills/statechart/scripts/frontends/config.ts +276 -0
- package/pstack/skills/statechart/scripts/frontends/dot.ts +74 -0
- package/pstack/skills/statechart/scripts/frontends/marks.ts +93 -0
- package/pstack/skills/statechart/scripts/frontends/messages.ts +52 -0
- package/pstack/skills/statechart/scripts/frontends/spec.ts +114 -0
- package/pstack/skills/statechart/scripts/frontends/trace.ts +24 -0
- package/pstack/skills/statechart/scripts/frontends/value.ts +166 -0
- package/pstack/skills/statechart/scripts/frontends/verdict.ts +40 -0
- package/pstack/skills/statechart/scripts/frontends/view.ts +119 -0
- package/pstack/skills/statechart/scripts/ir.ts +547 -0
- package/pstack/skills/statechart/scripts/package.json +11 -0
- package/pstack/skills/statechart/scripts/passes/annotate.ts +128 -0
- package/pstack/skills/statechart/scripts/passes/label.ts +269 -0
- package/pstack/skills/statechart/scripts/passes/lift.ts +85 -0
- package/pstack/skills/statechart/scripts/passes/loop-check.ts +68 -0
- package/pstack/skills/statechart/scripts/passes/paths.ts +60 -0
- package/pstack/skills/statechart/scripts/passes/reach.ts +135 -0
- package/pstack/skills/statechart/scripts/passes/region-check.ts +97 -0
- package/pstack/skills/statechart/scripts/passes/regions.ts +295 -0
- package/pstack/skills/statechart/scripts/pipeline.ts +76 -0
- package/pstack/skills/statechart/scripts/run.ts +481 -0
- package/pstack/skills/statechart/scripts/statechart +29 -0
- package/pstack/skills/statechart/scripts/statechart.ts +164 -0
- package/pstack/skills/statechart/scripts/test/ConfigOracle.java +63 -0
- package/pstack/skills/statechart/scripts/test/chart.test.ts +1210 -0
- package/pstack/skills/statechart/scripts/test/charts/Braces.mmd +7 -0
- package/pstack/skills/statechart/scripts/test/charts/Escapes.mmd +11 -0
- package/pstack/skills/statechart/scripts/test/charts/Phases.mmd +29 -0
- package/pstack/skills/statechart/scripts/test/cli.test.ts +1314 -0
- package/pstack/skills/statechart/scripts/test/config-fuzz.test.ts +263 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/Counter.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/Counter.tla +10 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/chart.mmd +9 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/graph.dot +16 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/report.md +7 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/Counter/verdict-1.out +49 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/ChartRun.out +60 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/CounterAction.cfg +4 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/CounterAction.tla +22 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/chart.mmd +26 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/graph.dot +19 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/report.md +20 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/verdict-2.out +82 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterAction/verdict-3.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/ChartRun.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/CounterDeadlock.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/CounterDeadlock.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/chart.mmd +22 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/graph.dot +16 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/report.md +17 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterDeadlock/verdict-2.out +77 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/ChartRun.out +69 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/CounterFan.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/CounterFan.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/chart.mmd +85 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/graph.dot +70 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/report.md +12 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/verdict-1.out +67 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterFan/verdict-2.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/ChartRun.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/ChartRun.out +85 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/CounterGuard.cfg +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/CounterGuard.tla +13 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/chart.mmd +5 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/graph.dot +10 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/report.md +31 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/verdict-1.out +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterGuard/verdict-2.out +77 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/ChartRun.out +55 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/CounterInitPast.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/CounterInitPast.tla +10 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/chart.mmd +12 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/graph.dot +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/report.md +12 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/verdict-1.out +33 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPast/verdict-2.out +54 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/ChartRun.out +54 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/CounterInitPastHolds.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/CounterInitPastHolds.tla +10 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/chart.mmd +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/graph.dot +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/report.md +7 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInitPastHolds/verdict-1.out +46 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/ChartRun.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/CounterInstance.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/CounterInstance.tla +10 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/CounterSteps.tla +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/chart.mmd +17 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/graph.dot +15 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/report.md +14 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/sany.out +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterInstance/verdict-1.out +78 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/ChartRun.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/CounterJump.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/CounterJump.tla +19 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/chart.mmd +26 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/graph.dot +22 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/report.md +12 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/verdict-1.out +58 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterJump/verdict-2.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/CounterLoop.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/CounterLoop.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/chart.mmd +17 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/graph.dot +15 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/report.md +14 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterLoop/verdict-1.out +76 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/ChartRun.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/CounterOrder.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/CounterOrder.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/chart.mmd +19 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/graph.dot +10 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/report.md +15 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterOrder/verdict-2.out +67 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/ChartRun.out +62 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/CounterRules.cfg +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/CounterRules.tla +24 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/Moves.tla +5 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/chart.mmd +22 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/graph.dot +10 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/report.md +23 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/sany.out +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/verdict-1.out +58 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/verdict-2.out +66 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/verdict-3.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/verdict-3.out +74 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterRules/verdict-4.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/ChartRun.out +58 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/CounterStart.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/CounterStart.tla +15 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/chart.mmd +18 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/graph.dot +13 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/report.md +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/verdict-1.out +33 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStart/verdict-2.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/CounterStop.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/CounterStop.tla +15 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/chart.mmd +7 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/graph.dot +13 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/report.md +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterStop/verdict-1.out +49 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/ChartRun.out +61 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/CounterTie.cfg +4 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/CounterTie.tla +14 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/chart.mmd +30 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/graph.dot +19 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/report.md +27 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/verdict-2.out +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/verdict-3.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/verdict-3.out +87 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTie/verdict-4.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/ChartRun.out +60 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/CounterTieInGraph.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/CounterTieInGraph.tla +12 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/chart.mmd +23 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/graph.dot +19 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/report.md +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterTieInGraph/verdict-2.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/ChartRun.out +61 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/CounterView.cfg +4 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/CounterView.tla +14 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/chart.mmd +23 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/graph.dot +19 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/report.md +27 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/verdict-2.out +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/verdict-3.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/verdict-3.out +87 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/verdict-4.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/CounterView/view.mjs +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/ChartRun.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/DieHard.cfg +4 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/DieHard.tla +38 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/chart.mmd +92 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/graph.dot +126 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/report.md +17 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/verdict-1.out +91 -0
- package/pstack/skills/statechart/scripts/test/corpus/DieHard/verdict-2.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/ChartRun.out +61 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/FirstRule.cfg +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/FirstRule.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/chart.mmd +22 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/graph.dot +16 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/report.md +25 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-2.out +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-3.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-3.out +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-4.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/FirstRule/verdict-4.out +77 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/HiddenClock.cfg +4 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/HiddenClock.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/chart.mmd +13 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/graph.dot +12 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/report.md +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/HiddenClock/verdict-1.out +72 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/Login.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/Login.tla +62 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/chart.mmd +27 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/graph.dot +40 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/report.md +7 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/verdict-1.out +47 -0
- package/pstack/skills/statechart/scripts/test/corpus/Login/view.mjs +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/LoginGuarded.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/LoginGuarded.tla +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/chart.mmd +28 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/graph.dot +37 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/report.md +8 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/verdict-1.out +47 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginGuarded/view.mjs +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/ChartRun.out +60 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/LoginParallel.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/LoginParallel.tla +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/chart.mmd +44 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/graph.dot +58 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/report.md +17 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/verdict-1.out +83 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/verdict-2.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/LoginParallel/view.mjs +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/ChartRun.out +60 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/MediaPlayer.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/MediaPlayer.tla +103 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/chart.mmd +43 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/graph.dot +93 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/report.md +14 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/verdict-1.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/verdict-2.out +72 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayer/view.mjs +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/MediaPlayerFixed.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/MediaPlayerFixed.tla +100 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/chart.mmd +31 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/graph.dot +85 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/report.md +9 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/verdict-1.out +47 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerFixed/view.mjs +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/ChartRun.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/MediaPlayer.tla +103 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/MediaPlayerProps.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/MediaPlayerProps.tla +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/chart.mmd +42 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/graph.dot +93 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/report.md +19 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-1.out +61 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-2.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-3.out +61 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-4.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-4.out +66 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-5.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-5.out +58 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/verdict-6.out +49 -0
- package/pstack/skills/statechart/scripts/test/corpus/MediaPlayerProps/view.mjs +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/PickWorker.cfg +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/PickWorker.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/chart.mmd +5 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/graph.dot +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/report.md +7 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/sany.out +5 -0
- package/pstack/skills/statechart/scripts/test/corpus/PickWorker/verdict-1.out +70 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/ChartRun.out +61 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/Shadow.cfg +4 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/Shadow.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/ShadowLib.tla +6 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/ShadowSub.tla +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/chart.mmd +9 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/graph.dot +16 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/report.md +8 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/sany.out +4 -0
- package/pstack/skills/statechart/scripts/test/corpus/Shadow/verdict-1.out +65 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/ChartRun.out +59 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/SpacedNames.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/SpacedNames.tla +9 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/chart.mmd +23 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/graph.dot +17 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/report.md +15 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/verdict-1.out +65 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/SpacedNames/verdict-2.out +75 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/ChartRun.out +69 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/TwoPhase.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/TwoPhase.tla +75 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/chart.mmd +60 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/graph.dot +297 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/report.md +20 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/verdict-1.out +95 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/verdict-2.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhase/view.mjs +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/ChartRun.out +57 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/TwoPhaseFixed.cfg +3 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/TwoPhaseFixed.tla +75 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/chart.mmd +37 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/graph.dot +223 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/report.md +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/sany.out +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/verdict-1.out +47 -0
- package/pstack/skills/statechart/scripts/test/corpus/TwoPhaseFixed/view.mjs +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/ChartRun.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/ChartRun.out +75 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/TypeGuard.cfg +5 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/TypeGuard.tla +11 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/chart.mmd +18 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/graph.dot +14 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/report.md +29 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/verdict-1.out +64 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/TypeGuard/verdict-2.out +75 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/ChartRun.out +58 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/UserNoDeadlock.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/UserNoDeadlock.tla +8 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/chart.mmd +22 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/graph.dot +16 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/report.md +15 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/verdict-1.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/verdict-1.out +56 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/verdict-2.exit +1 -0
- package/pstack/skills/statechart/scripts/test/corpus/UserNoDeadlock/verdict-2.out +77 -0
- package/pstack/skills/statechart/scripts/test/corpus.test.ts +403 -0
- package/pstack/skills/statechart/scripts/test/differential.test.ts +565 -0
- package/pstack/skills/statechart/scripts/test/grid/Grid.cfg +2 -0
- package/pstack/skills/statechart/scripts/test/grid/Grid.tla +9 -0
- package/pstack/skills/statechart/scripts/test/grid/sany.out +2 -0
- package/pstack/skills/statechart/scripts/test/java.ts +63 -0
- package/pstack/skills/statechart/scripts/test/labels.ts +643 -0
- package/pstack/skills/statechart/scripts/test/messages.test.ts +212 -0
- package/pstack/skills/statechart/scripts/test/pipeline.test.ts +270 -0
- package/pstack/skills/statechart/scripts/test/plain-tlc.test.ts +255 -0
- package/pstack/skills/statechart/scripts/test/render.test.ts +81 -0
- package/pstack/skills/statechart/scripts/test/tlc-out.test.ts +90 -0
- package/pstack/skills/statechart/scripts/test/tlc.ts +158 -0
- package/pstack/skills/statechart/scripts/tsconfig.json +11 -0
- package/pstack/skills/statechart/scripts/worker.ts +35 -0
- package/pstack/skills/swarm/SKILL.md +47 -0
- package/pstack/skills/tdd/SKILL.md +42 -0
- package/pstack/skills/teach/SKILL.md +21 -0
- package/pstack/skills/technical-writing/SKILL.md +106 -0
- package/pstack/skills/thermo-nuclear-code-quality-review/SKILL.md +192 -0
- package/pstack/skills/thermo-nuclear-review/SKILL.md +51 -0
- package/pstack/skills/thermos/SKILL.md +21 -0
- package/pstack/skills/typescript-best-practices/SKILL.md +31 -0
- package/pstack/skills/typescript-best-practices/references/patterns.md +328 -0
- package/pstack/skills/unslop/SKILL.md +62 -0
- package/pstack/skills/what-did-i-get-done/SKILL.md +31 -0
- package/pstack/skills/why/SKILL.md +105 -0
- package/pstack/skills/why/references/epistemics.md +71 -0
- package/pstack/skills/why/references/investigator-prompt.md +84 -0
- package/pstack/skills/why/references/source-playbook.md +17 -0
- package/pstack/skills/why/references/sources/code-archaeology.md +51 -0
- package/pstack/skills/why/references/sources/databricks.md +70 -0
- package/pstack/skills/why/references/sources/datadog.md +97 -0
- package/pstack/skills/why/references/sources/incident-postmortem.md +5 -0
- package/pstack/skills/why/references/sources/linear.md +48 -0
- package/pstack/skills/why/references/sources/notion.md +55 -0
- package/pstack/skills/why/references/sources/sentry.md +66 -0
- package/pstack/skills/why/references/sources/slack.md +17 -0
- package/pstack/skills/why/references/synthesizer-prompt.md +129 -0
- package/src/accounts.ts +527 -0
- package/src/bash-timeout.ts +63 -0
- package/src/bridge-trim.ts +109 -0
- package/src/brief.ts +280 -0
- package/src/cards.ts +65 -0
- package/src/child.ts +570 -0
- package/src/failures.ts +73 -0
- package/src/models.ts +1249 -0
- package/src/plan.ts +252 -0
- package/src/resources.ts +30 -0
- package/src/results.ts +92 -0
- package/src/resume.ts +143 -0
- package/src/session.ts +70 -0
- package/src/state.ts +124 -0
- package/src/t3-http.ts +140 -0
- package/src/t3-json.ts +50 -0
- package/src/t3-mcp.ts +188 -0
- package/src/tasks.ts +163 -0
- package/src/transcript.ts +17 -0
- package/src/usage.ts +145 -0
- package/README.md +0 -3
|
@@ -0,0 +1,796 @@
|
|
|
1
|
+
// Michael Denyer's watch-pr fixes from pstack-claude, carried by t3-pstack:
|
|
2
|
+
// a PR that waits on a required review or another protection rule is not
|
|
3
|
+
// READY (#95), a stale check fails instead of pending forever (#97), a
|
|
4
|
+
// repository with no checks configured gets a verdict instead of retrying
|
|
5
|
+
// forever (#151, #152, #153), and a BLOCKED read stops the watcher only once
|
|
6
|
+
// it has held for 60 seconds (#223).
|
|
7
|
+
import { afterEach, describe, expect, it } from "../test-utils/node-test.ts";
|
|
8
|
+
import { spawnSync } from "node:child_process";
|
|
9
|
+
import {
|
|
10
|
+
chmodSync,
|
|
11
|
+
mkdirSync,
|
|
12
|
+
mkdtempSync,
|
|
13
|
+
rmSync,
|
|
14
|
+
writeFileSync,
|
|
15
|
+
} from "node:fs";
|
|
16
|
+
import { tmpdir } from "node:os";
|
|
17
|
+
import { join } from "node:path";
|
|
18
|
+
import { type CliRuntime, main } from "./cli.ts";
|
|
19
|
+
import {
|
|
20
|
+
type FakeReaderOptions,
|
|
21
|
+
fakeReader,
|
|
22
|
+
passingCheck,
|
|
23
|
+
pendingCheck,
|
|
24
|
+
} from "./fakes.test-helper.ts";
|
|
25
|
+
import {
|
|
26
|
+
ChecksUnavailable,
|
|
27
|
+
WatcherQueryError,
|
|
28
|
+
parseFastCheck,
|
|
29
|
+
resolveChecks,
|
|
30
|
+
} from "./github.ts";
|
|
31
|
+
import {
|
|
32
|
+
classifyPr,
|
|
33
|
+
readSnapshot,
|
|
34
|
+
selectTierMajorStackDecision,
|
|
35
|
+
} from "./policy.ts";
|
|
36
|
+
import type { GitHubReader, NonEmpty, PrContext, PrSnapshot } from "./types.ts";
|
|
37
|
+
import { parsePrNumber } from "./types.ts";
|
|
38
|
+
|
|
39
|
+
const context = (number: number) => ({
|
|
40
|
+
owner: "owner",
|
|
41
|
+
repo: "repo",
|
|
42
|
+
number: parsePrNumber(number),
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
// A clock that moves only when the watcher sleeps, so a reader can change what
|
|
46
|
+
// GitHub reports between polls.
|
|
47
|
+
function tickingRuntime() {
|
|
48
|
+
let now = 0;
|
|
49
|
+
const stdout: string[] = [];
|
|
50
|
+
return {
|
|
51
|
+
now: () => now,
|
|
52
|
+
text: () => stdout.join(""),
|
|
53
|
+
verdicts: () => stdout.map((line) => JSON.parse(line) as unknown),
|
|
54
|
+
runtime: (reader: GitHubReader): CliRuntime => ({
|
|
55
|
+
reader,
|
|
56
|
+
clock: {
|
|
57
|
+
now: () => now,
|
|
58
|
+
observedAt: () =>
|
|
59
|
+
new Date(
|
|
60
|
+
Date.parse("2026-07-26T00:00:00.000Z") + now * 1_000
|
|
61
|
+
).toISOString(),
|
|
62
|
+
async sleep(seconds) {
|
|
63
|
+
now += seconds;
|
|
64
|
+
if (now > 3_600) throw new Error("watched for over an hour");
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
stdout: (value) => stdout.push(value),
|
|
68
|
+
stderr: () => {},
|
|
69
|
+
}),
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// gh reports no checks, and the head commit has no rollup.
|
|
74
|
+
const noChecks = {
|
|
75
|
+
fastPath: { kind: "none-reported" },
|
|
76
|
+
rollupPages: [{ kind: "no-rollup" }],
|
|
77
|
+
commitRollups: [{ oid: "head", state: null }],
|
|
78
|
+
} as const;
|
|
79
|
+
|
|
80
|
+
function testRuntime(reader: GitHubReader) {
|
|
81
|
+
const stdout: string[] = [];
|
|
82
|
+
const runtime: CliRuntime = {
|
|
83
|
+
reader,
|
|
84
|
+
clock: {
|
|
85
|
+
now: () => 0,
|
|
86
|
+
observedAt: () => "2026-07-26T00:00:00.000Z",
|
|
87
|
+
async sleep() {
|
|
88
|
+
throw new Error("test unexpectedly slept");
|
|
89
|
+
},
|
|
90
|
+
},
|
|
91
|
+
stdout: (value) => stdout.push(value),
|
|
92
|
+
stderr: () => {},
|
|
93
|
+
};
|
|
94
|
+
return { runtime, stdout };
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
const single = [
|
|
98
|
+
"--owner",
|
|
99
|
+
"owner",
|
|
100
|
+
"--repo",
|
|
101
|
+
"repo",
|
|
102
|
+
"--pr",
|
|
103
|
+
"1",
|
|
104
|
+
"--settle",
|
|
105
|
+
"0",
|
|
106
|
+
];
|
|
107
|
+
|
|
108
|
+
describe("review gate", () => {
|
|
109
|
+
it("blocks on a required review instead of reporting a blocked PR ready", async () => {
|
|
110
|
+
const snapshot = await readSnapshot({
|
|
111
|
+
reader: fakeReader({
|
|
112
|
+
facts: {
|
|
113
|
+
reviewDecision: "REVIEW_REQUIRED",
|
|
114
|
+
mergeStateStatus: "BLOCKED",
|
|
115
|
+
},
|
|
116
|
+
}),
|
|
117
|
+
context: context(23),
|
|
118
|
+
pendingHistory: "omit",
|
|
119
|
+
allowDraft: false,
|
|
120
|
+
});
|
|
121
|
+
expect(classifyPr(snapshot)).toEqual({
|
|
122
|
+
kind: "blocker",
|
|
123
|
+
blocker: {
|
|
124
|
+
kind: "merge-gate",
|
|
125
|
+
pr: context(23),
|
|
126
|
+
reason: "review-required",
|
|
127
|
+
},
|
|
128
|
+
});
|
|
129
|
+
expect(
|
|
130
|
+
selectTierMajorStackDecision([snapshot] as NonEmpty<PrSnapshot>)
|
|
131
|
+
).toMatchObject({
|
|
132
|
+
kind: "blocker",
|
|
133
|
+
blocker: { kind: "merge-gate", reason: "review-required" },
|
|
134
|
+
});
|
|
135
|
+
});
|
|
136
|
+
|
|
137
|
+
it("blocks when branch protection holds an approved PR with clean CI", async () => {
|
|
138
|
+
const snapshot = await readSnapshot({
|
|
139
|
+
reader: fakeReader({ facts: { mergeStateStatus: "BLOCKED" } }),
|
|
140
|
+
context: context(24),
|
|
141
|
+
pendingHistory: "omit",
|
|
142
|
+
allowDraft: false,
|
|
143
|
+
});
|
|
144
|
+
expect(classifyPr(snapshot)).toMatchObject({
|
|
145
|
+
kind: "blocker",
|
|
146
|
+
blocker: { kind: "merge-gate", reason: "merge-blocked" },
|
|
147
|
+
});
|
|
148
|
+
});
|
|
149
|
+
|
|
150
|
+
it("waits for pending checks before reporting the review gate", async () => {
|
|
151
|
+
const snapshot = await readSnapshot({
|
|
152
|
+
reader: fakeReader({
|
|
153
|
+
facts: {
|
|
154
|
+
reviewDecision: "REVIEW_REQUIRED",
|
|
155
|
+
mergeStateStatus: "BLOCKED",
|
|
156
|
+
},
|
|
157
|
+
fastPath: { kind: "checks", checks: [pendingCheck()] },
|
|
158
|
+
}),
|
|
159
|
+
context: context(26),
|
|
160
|
+
pendingHistory: "omit",
|
|
161
|
+
allowDraft: false,
|
|
162
|
+
});
|
|
163
|
+
expect(classifyPr(snapshot)).toMatchObject({ kind: "waiting" });
|
|
164
|
+
});
|
|
165
|
+
|
|
166
|
+
it("waits out t3-pstack's review settle window before reporting the review gate", async () => {
|
|
167
|
+
const read = (settling: boolean) =>
|
|
168
|
+
readSnapshot({
|
|
169
|
+
reader: fakeReader({
|
|
170
|
+
facts: {
|
|
171
|
+
reviewDecision: "REVIEW_REQUIRED",
|
|
172
|
+
mergeStateStatus: "BLOCKED",
|
|
173
|
+
},
|
|
174
|
+
}),
|
|
175
|
+
context: context(27),
|
|
176
|
+
pendingHistory: "include",
|
|
177
|
+
allowDraft: false,
|
|
178
|
+
settler: async () =>
|
|
179
|
+
settling
|
|
180
|
+
? {
|
|
181
|
+
kind: "settling",
|
|
182
|
+
since: { at: "2026-07-26T00:00:00.000Z", source: "push" },
|
|
183
|
+
lastActivityAt: null,
|
|
184
|
+
endsAt: "2026-07-26T00:05:00.000Z",
|
|
185
|
+
secondsLeft: 300,
|
|
186
|
+
heldBy: "activity",
|
|
187
|
+
}
|
|
188
|
+
: {
|
|
189
|
+
kind: "settled",
|
|
190
|
+
since: { at: "2026-07-26T00:00:00.000Z", source: "push" },
|
|
191
|
+
lastActivityAt: null,
|
|
192
|
+
},
|
|
193
|
+
});
|
|
194
|
+
expect(classifyPr(await read(true))).toMatchObject({ kind: "settling" });
|
|
195
|
+
expect(classifyPr(await read(false))).toMatchObject({
|
|
196
|
+
kind: "blocker",
|
|
197
|
+
blocker: { kind: "merge-gate", reason: "review-required" },
|
|
198
|
+
});
|
|
199
|
+
});
|
|
200
|
+
|
|
201
|
+
it("still reports changes requested as a merge-gate blocker", async () => {
|
|
202
|
+
const snapshot = await readSnapshot({
|
|
203
|
+
reader: fakeReader({
|
|
204
|
+
facts: {
|
|
205
|
+
reviewDecision: "CHANGES_REQUESTED",
|
|
206
|
+
mergeStateStatus: "BLOCKED",
|
|
207
|
+
},
|
|
208
|
+
}),
|
|
209
|
+
context: context(25),
|
|
210
|
+
pendingHistory: "omit",
|
|
211
|
+
allowDraft: false,
|
|
212
|
+
});
|
|
213
|
+
expect(classifyPr(snapshot)).toMatchObject({
|
|
214
|
+
kind: "blocker",
|
|
215
|
+
blocker: { kind: "merge-gate", reason: "changes-requested" },
|
|
216
|
+
});
|
|
217
|
+
});
|
|
218
|
+
|
|
219
|
+
it("exits 6 and names the review in the status table and the blocker", async () => {
|
|
220
|
+
const reader = () =>
|
|
221
|
+
fakeReader({
|
|
222
|
+
facts: {
|
|
223
|
+
reviewDecision: "REVIEW_REQUIRED",
|
|
224
|
+
mergeStateStatus: "BLOCKED",
|
|
225
|
+
},
|
|
226
|
+
});
|
|
227
|
+
const status = testRuntime(reader());
|
|
228
|
+
expect(
|
|
229
|
+
await main([...single, "--pretty", "--status-only"], status.runtime)
|
|
230
|
+
).toBe(0);
|
|
231
|
+
expect(status.stdout.join("")).toContain(
|
|
232
|
+
"| [#1](https://github.com/owner/repo/pull/1) | ✅ | 👀 review required | ⛔ blocked |"
|
|
233
|
+
);
|
|
234
|
+
const watch = tickingRuntime();
|
|
235
|
+
expect(await main([...single, "--pretty"], watch.runtime(reader()))).toBe(
|
|
236
|
+
6
|
|
237
|
+
);
|
|
238
|
+
expect(watch.text()).toBe(
|
|
239
|
+
"WAITING: frontier=#1; confirming merge block (GitHub reads BLOCKED; stops if the same head still does after 60s)\nBLOCKER: review-required\npr=1\naction=human action needed: a required approving review is missing; report it and wait for a reviewer\n"
|
|
240
|
+
);
|
|
241
|
+
});
|
|
242
|
+
|
|
243
|
+
it("gates only the stack's frontier on a review or branch protection", async () => {
|
|
244
|
+
const approved = await readSnapshot({
|
|
245
|
+
reader: fakeReader(),
|
|
246
|
+
context: context(31),
|
|
247
|
+
pendingHistory: "include",
|
|
248
|
+
allowDraft: false,
|
|
249
|
+
});
|
|
250
|
+
const needsReview = await readSnapshot({
|
|
251
|
+
reader: fakeReader({
|
|
252
|
+
facts: {
|
|
253
|
+
reviewDecision: "REVIEW_REQUIRED",
|
|
254
|
+
mergeStateStatus: "BLOCKED",
|
|
255
|
+
},
|
|
256
|
+
}),
|
|
257
|
+
context: context(32),
|
|
258
|
+
pendingHistory: "include",
|
|
259
|
+
allowDraft: false,
|
|
260
|
+
});
|
|
261
|
+
expect(selectTierMajorStackDecision([approved, needsReview])).toMatchObject(
|
|
262
|
+
{ kind: "clear", prs: [{ kind: "ready-pr" }, { kind: "ready-pr" }] }
|
|
263
|
+
);
|
|
264
|
+
expect(selectTierMajorStackDecision([needsReview, approved])).toMatchObject(
|
|
265
|
+
{
|
|
266
|
+
kind: "blocker",
|
|
267
|
+
blocker: {
|
|
268
|
+
kind: "merge-gate",
|
|
269
|
+
pr: context(32),
|
|
270
|
+
reason: "review-required",
|
|
271
|
+
},
|
|
272
|
+
}
|
|
273
|
+
);
|
|
274
|
+
});
|
|
275
|
+
|
|
276
|
+
it("waits on a queued frontier while the PRs above it need review, then stops at the next one", async () => {
|
|
277
|
+
const base = fakeReader();
|
|
278
|
+
let frontierReads = 0;
|
|
279
|
+
const reader = {
|
|
280
|
+
...base,
|
|
281
|
+
async pullRequest(pr: PrContext) {
|
|
282
|
+
const facts = await base.pullRequest(pr);
|
|
283
|
+
if (pr.number !== 1)
|
|
284
|
+
return {
|
|
285
|
+
...facts,
|
|
286
|
+
reviewDecision: "REVIEW_REQUIRED" as const,
|
|
287
|
+
mergeStateStatus: "BLOCKED" as const,
|
|
288
|
+
};
|
|
289
|
+
frontierReads += 1;
|
|
290
|
+
return frontierReads === 1
|
|
291
|
+
? facts
|
|
292
|
+
: {
|
|
293
|
+
...facts,
|
|
294
|
+
state: "MERGED" as const,
|
|
295
|
+
mergedAt: "2026-07-26T00:01:00Z",
|
|
296
|
+
};
|
|
297
|
+
},
|
|
298
|
+
} satisfies GitHubReader;
|
|
299
|
+
const watch = tickingRuntime();
|
|
300
|
+
expect(
|
|
301
|
+
await main(
|
|
302
|
+
[
|
|
303
|
+
"--owner",
|
|
304
|
+
"owner",
|
|
305
|
+
"--repo",
|
|
306
|
+
"repo",
|
|
307
|
+
"--queued-stack",
|
|
308
|
+
"--stack-prs",
|
|
309
|
+
"1,2,3",
|
|
310
|
+
],
|
|
311
|
+
watch.runtime(reader)
|
|
312
|
+
)
|
|
313
|
+
).toBe(6);
|
|
314
|
+
expect(watch.verdicts()).toMatchObject([
|
|
315
|
+
{ kind: "QUEUE" },
|
|
316
|
+
{ kind: "STATUS", reason: "whole-stack-sweep" },
|
|
317
|
+
{
|
|
318
|
+
kind: "WAITING",
|
|
319
|
+
frontier: { number: 1 },
|
|
320
|
+
reason: { kind: "merge-queue", unmergedCount: 3 },
|
|
321
|
+
},
|
|
322
|
+
{
|
|
323
|
+
kind: "WAITING",
|
|
324
|
+
frontier: { number: 2 },
|
|
325
|
+
reason: { kind: "confirming-block" },
|
|
326
|
+
},
|
|
327
|
+
{
|
|
328
|
+
kind: "BLOCKER",
|
|
329
|
+
exitCode: 6,
|
|
330
|
+
blocker: {
|
|
331
|
+
kind: "merge-gate",
|
|
332
|
+
pr: { number: 2 },
|
|
333
|
+
reason: "review-required",
|
|
334
|
+
},
|
|
335
|
+
},
|
|
336
|
+
]);
|
|
337
|
+
});
|
|
338
|
+
});
|
|
339
|
+
|
|
340
|
+
describe("a frontier with clean CI that reads BLOCKED for a moment", () => {
|
|
341
|
+
// Reads as `fakeReader(polls[n])` during the nth 60-second poll.
|
|
342
|
+
function pollsReader(now: () => number, polls: readonly FakeReaderOptions[]) {
|
|
343
|
+
const readers = polls.map((options) => fakeReader(options));
|
|
344
|
+
const at = () => {
|
|
345
|
+
const reader = readers[Math.floor(now() / 60)];
|
|
346
|
+
if (reader === undefined) throw new Error("read past the last poll");
|
|
347
|
+
return reader;
|
|
348
|
+
};
|
|
349
|
+
return {
|
|
350
|
+
...fakeReader(),
|
|
351
|
+
pullRequest: (pr: PrContext) => at().pullRequest(pr),
|
|
352
|
+
checksFastPath: (pr: PrContext) => at().checksFastPath(pr),
|
|
353
|
+
commitRollups: (pr: PrContext) => at().commitRollups(pr),
|
|
354
|
+
} satisfies GitHubReader;
|
|
355
|
+
}
|
|
356
|
+
const blocked = { facts: { mergeStateStatus: "BLOCKED" } } as const;
|
|
357
|
+
|
|
358
|
+
it("reaches READY when the block clears within 60 seconds", async () => {
|
|
359
|
+
const watch = tickingRuntime();
|
|
360
|
+
expect(
|
|
361
|
+
await main(single, watch.runtime(pollsReader(watch.now, [blocked, {}])))
|
|
362
|
+
).toBe(0);
|
|
363
|
+
expect(watch.verdicts()).toMatchObject([
|
|
364
|
+
{
|
|
365
|
+
kind: "WAITING",
|
|
366
|
+
frontier: { number: 1 },
|
|
367
|
+
reason: { kind: "confirming-block" },
|
|
368
|
+
},
|
|
369
|
+
{ kind: "READY", exitCode: 0 },
|
|
370
|
+
]);
|
|
371
|
+
});
|
|
372
|
+
|
|
373
|
+
it("stops confirming at the deadline instead of sleeping past it", async () => {
|
|
374
|
+
const watch = tickingRuntime();
|
|
375
|
+
expect(
|
|
376
|
+
await main(
|
|
377
|
+
[...single, "--timeout", "30"],
|
|
378
|
+
watch.runtime(pollsReader(watch.now, [blocked, blocked]))
|
|
379
|
+
)
|
|
380
|
+
).toBe(5);
|
|
381
|
+
expect(watch.verdicts()).toMatchObject([
|
|
382
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
383
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
384
|
+
{ kind: "TIMEOUT", exitCode: 5, reason: { kind: "confirming-block" } },
|
|
385
|
+
]);
|
|
386
|
+
expect(watch.now()).toBe(30);
|
|
387
|
+
});
|
|
388
|
+
|
|
389
|
+
it("does not count BLOCKED reads while a check is pending", async () => {
|
|
390
|
+
const pending = {
|
|
391
|
+
...blocked,
|
|
392
|
+
fastPath: { kind: "checks", checks: [pendingCheck()] },
|
|
393
|
+
commitRollups: [{ oid: "head", state: "PENDING" }],
|
|
394
|
+
} as const;
|
|
395
|
+
const watch = tickingRuntime();
|
|
396
|
+
expect(
|
|
397
|
+
await main(
|
|
398
|
+
single,
|
|
399
|
+
watch.runtime(pollsReader(watch.now, [pending, pending, blocked, {}]))
|
|
400
|
+
)
|
|
401
|
+
).toBe(0);
|
|
402
|
+
expect(watch.verdicts()).toMatchObject([
|
|
403
|
+
{ kind: "WAITING", reason: { kind: "pending-checks" } },
|
|
404
|
+
{ kind: "WAITING", reason: { kind: "pending-checks" } },
|
|
405
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
406
|
+
{ kind: "READY", exitCode: 0 },
|
|
407
|
+
]);
|
|
408
|
+
});
|
|
409
|
+
|
|
410
|
+
it("confirms again each time a queued frontier flips back to BLOCKED", async () => {
|
|
411
|
+
const watch = tickingRuntime();
|
|
412
|
+
expect(
|
|
413
|
+
await main(
|
|
414
|
+
[
|
|
415
|
+
"--owner",
|
|
416
|
+
"owner",
|
|
417
|
+
"--repo",
|
|
418
|
+
"repo",
|
|
419
|
+
"--queued-stack",
|
|
420
|
+
"--stack-prs",
|
|
421
|
+
"1",
|
|
422
|
+
],
|
|
423
|
+
watch.runtime(
|
|
424
|
+
pollsReader(watch.now, [
|
|
425
|
+
blocked,
|
|
426
|
+
{},
|
|
427
|
+
blocked,
|
|
428
|
+
{ facts: { state: "MERGED", mergedAt: "2026-07-26T00:03:00Z" } },
|
|
429
|
+
])
|
|
430
|
+
)
|
|
431
|
+
)
|
|
432
|
+
).toBe(0);
|
|
433
|
+
expect(watch.verdicts()).toMatchObject([
|
|
434
|
+
{ kind: "QUEUE" },
|
|
435
|
+
{ kind: "STATUS", reason: "whole-stack-sweep" },
|
|
436
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
437
|
+
{ kind: "WAITING", reason: { kind: "merge-queue" } },
|
|
438
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
439
|
+
{ kind: "COMPLETE", exitCode: 0 },
|
|
440
|
+
]);
|
|
441
|
+
});
|
|
442
|
+
});
|
|
443
|
+
|
|
444
|
+
describe("a just-pushed head that GitHub blocks before any check registers", () => {
|
|
445
|
+
// Reads `noChecks` and BLOCKED until `registersAt`, then a pending required
|
|
446
|
+
// check, then the check passed and the PR clean.
|
|
447
|
+
function pushedReader(now: () => number, registersAt: number) {
|
|
448
|
+
const phases = [
|
|
449
|
+
fakeReader({ ...noChecks, facts: { mergeStateStatus: "BLOCKED" } }),
|
|
450
|
+
fakeReader({
|
|
451
|
+
facts: { mergeStateStatus: "BLOCKED" },
|
|
452
|
+
fastPath: { kind: "checks", checks: [pendingCheck()] },
|
|
453
|
+
commitRollups: [{ oid: "head", state: "PENDING" }],
|
|
454
|
+
}),
|
|
455
|
+
fakeReader(),
|
|
456
|
+
] as const;
|
|
457
|
+
const at = () =>
|
|
458
|
+
phases[now() < registersAt ? 0 : now() < registersAt + 60 ? 1 : 2];
|
|
459
|
+
return {
|
|
460
|
+
...phases[0],
|
|
461
|
+
pullRequest: (pr: PrContext) => at().pullRequest(pr),
|
|
462
|
+
checksFastPath: (pr: PrContext) => at().checksFastPath(pr),
|
|
463
|
+
checkRollupPage: async () => ({ kind: "no-rollup" }) as const,
|
|
464
|
+
commitRollups: (pr: PrContext) => at().commitRollups(pr),
|
|
465
|
+
} satisfies GitHubReader;
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
it("waits for the required check with the settle window off", async () => {
|
|
469
|
+
const watch = tickingRuntime();
|
|
470
|
+
expect(await main(single, watch.runtime(pushedReader(watch.now, 60)))).toBe(
|
|
471
|
+
0
|
|
472
|
+
);
|
|
473
|
+
expect(watch.verdicts()).toMatchObject([
|
|
474
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
475
|
+
{ kind: "WAITING", reason: { kind: "pending-checks" } },
|
|
476
|
+
{ kind: "READY", exitCode: 0 },
|
|
477
|
+
]);
|
|
478
|
+
});
|
|
479
|
+
|
|
480
|
+
it("stops at the merge gate once the block has held for 60 seconds, without spending the query-error budget", async () => {
|
|
481
|
+
const watch = tickingRuntime();
|
|
482
|
+
expect(
|
|
483
|
+
await main(
|
|
484
|
+
[...single, "--max-query-errors", "1"],
|
|
485
|
+
watch.runtime(pushedReader(watch.now, Infinity))
|
|
486
|
+
)
|
|
487
|
+
).toBe(6);
|
|
488
|
+
expect(watch.now()).toBe(60);
|
|
489
|
+
expect(watch.verdicts()).toMatchObject([
|
|
490
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
491
|
+
{
|
|
492
|
+
kind: "BLOCKER",
|
|
493
|
+
exitCode: 6,
|
|
494
|
+
blocker: { kind: "merge-gate", reason: "merge-blocked" },
|
|
495
|
+
},
|
|
496
|
+
]);
|
|
497
|
+
});
|
|
498
|
+
});
|
|
499
|
+
|
|
500
|
+
describe("fast-path check mapping", () => {
|
|
501
|
+
// gh's aggregate.go files every state it does not name into the pending
|
|
502
|
+
// bucket, including completed conclusions.
|
|
503
|
+
it("fails completed conclusions that gh buckets as pending", () => {
|
|
504
|
+
for (const state of ["STARTUP_FAILURE", "STALE"]) {
|
|
505
|
+
expect(
|
|
506
|
+
parseFastCheck({ name: "ci", state, bucket: "pending" })
|
|
507
|
+
).toMatchObject({
|
|
508
|
+
kind: "failed",
|
|
509
|
+
reportedState: state,
|
|
510
|
+
});
|
|
511
|
+
}
|
|
512
|
+
});
|
|
513
|
+
|
|
514
|
+
it("keeps in-flight states pending", () => {
|
|
515
|
+
for (const state of [
|
|
516
|
+
"EXPECTED",
|
|
517
|
+
"REQUESTED",
|
|
518
|
+
"WAITING",
|
|
519
|
+
"QUEUED",
|
|
520
|
+
"PENDING",
|
|
521
|
+
"IN_PROGRESS",
|
|
522
|
+
]) {
|
|
523
|
+
expect(
|
|
524
|
+
parseFastCheck({ name: "ci", state, bucket: "pending" })
|
|
525
|
+
).toMatchObject({
|
|
526
|
+
kind: "pending",
|
|
527
|
+
reportedState: state,
|
|
528
|
+
});
|
|
529
|
+
}
|
|
530
|
+
});
|
|
531
|
+
|
|
532
|
+
it("stops at a stale check instead of waiting on it", async () => {
|
|
533
|
+
const stale = parseFastCheck({
|
|
534
|
+
name: "ci",
|
|
535
|
+
state: "STALE",
|
|
536
|
+
bucket: "pending",
|
|
537
|
+
});
|
|
538
|
+
const watch = testRuntime(
|
|
539
|
+
fakeReader({
|
|
540
|
+
fastPath: { kind: "checks", checks: [passingCheck("lint"), stale] },
|
|
541
|
+
})
|
|
542
|
+
);
|
|
543
|
+
expect(await main(single, watch.runtime)).toBe(4);
|
|
544
|
+
expect(JSON.parse(watch.stdout[0])).toMatchObject({
|
|
545
|
+
kind: "BLOCKER",
|
|
546
|
+
blocker: {
|
|
547
|
+
kind: "failing-checks",
|
|
548
|
+
ci: { failed: [{ name: "ci", reportedState: "STALE" }] },
|
|
549
|
+
},
|
|
550
|
+
});
|
|
551
|
+
});
|
|
552
|
+
});
|
|
553
|
+
|
|
554
|
+
describe("checks with none configured", () => {
|
|
555
|
+
it("reads no checks when gh reports none and the head commit has no rollup", async () => {
|
|
556
|
+
const reader = fakeReader({
|
|
557
|
+
fastPath: { kind: "none-reported" },
|
|
558
|
+
rollupPages: [{ kind: "no-rollup" }],
|
|
559
|
+
});
|
|
560
|
+
expect(await resolveChecks(reader, context(42))).toEqual({
|
|
561
|
+
source: "none",
|
|
562
|
+
checks: [],
|
|
563
|
+
});
|
|
564
|
+
expect(reader.calls).toEqual(["checksFastPath", "checkRollupPage:null"]);
|
|
565
|
+
});
|
|
566
|
+
|
|
567
|
+
it("fails closed when only one read says there are no checks", async () => {
|
|
568
|
+
const oneSided = [
|
|
569
|
+
{
|
|
570
|
+
fastPath: { kind: "unusable", exitCode: 1, stderr: "HTTP 401" },
|
|
571
|
+
rollupPages: [{ kind: "no-rollup" }],
|
|
572
|
+
},
|
|
573
|
+
{
|
|
574
|
+
fastPath: { kind: "checks", checks: [] },
|
|
575
|
+
rollupPages: [{ kind: "no-rollup" }],
|
|
576
|
+
},
|
|
577
|
+
{
|
|
578
|
+
fastPath: { kind: "none-reported" },
|
|
579
|
+
rollupPages: [{ checks: [], endCursor: null }],
|
|
580
|
+
},
|
|
581
|
+
] as const;
|
|
582
|
+
for (const options of oneSided)
|
|
583
|
+
await expect(
|
|
584
|
+
resolveChecks(fakeReader(options), context(42))
|
|
585
|
+
).rejects.toBeInstanceOf(ChecksUnavailable);
|
|
586
|
+
});
|
|
587
|
+
|
|
588
|
+
it("propagates a failed rollup query instead of reading it as no checks", async () => {
|
|
589
|
+
const reader = fakeReader({ fastPath: { kind: "none-reported" } });
|
|
590
|
+
const failure = new WatcherQueryError({
|
|
591
|
+
kind: "command-exit",
|
|
592
|
+
retryable: true,
|
|
593
|
+
code: 1,
|
|
594
|
+
detail: "HTTP 502",
|
|
595
|
+
});
|
|
596
|
+
reader.checkRollupPage = async () => {
|
|
597
|
+
throw failure;
|
|
598
|
+
};
|
|
599
|
+
await expect(resolveChecks(reader, context(42))).rejects.toBe(failure);
|
|
600
|
+
});
|
|
601
|
+
});
|
|
602
|
+
|
|
603
|
+
describe("a PR with no checks configured", () => {
|
|
604
|
+
const read = (overrides: Parameters<typeof fakeReader>[0] = {}) =>
|
|
605
|
+
readSnapshot({
|
|
606
|
+
reader: fakeReader({ ...noChecks, ...overrides }),
|
|
607
|
+
context: context(30),
|
|
608
|
+
pendingHistory: "omit",
|
|
609
|
+
allowDraft: false,
|
|
610
|
+
});
|
|
611
|
+
|
|
612
|
+
it("is ready when GitHub reports it mergeable", async () => {
|
|
613
|
+
const snapshot = await read({ facts: { reviewDecision: null } });
|
|
614
|
+
expect(classifyPr(snapshot)).toMatchObject({
|
|
615
|
+
kind: "ready",
|
|
616
|
+
pr: { proof: { ci: { kind: "ci-none" } } },
|
|
617
|
+
});
|
|
618
|
+
});
|
|
619
|
+
|
|
620
|
+
it("still stops on conflicts, review threads, and merge gates", async () => {
|
|
621
|
+
const thread = {
|
|
622
|
+
id: "thread",
|
|
623
|
+
firstComment: null,
|
|
624
|
+
isBugbot: false,
|
|
625
|
+
bugbotReviewPasses: 0,
|
|
626
|
+
};
|
|
627
|
+
const cases = [
|
|
628
|
+
[{ facts: { mergeable: "CONFLICTING" } }, { kind: "merge-conflicts" }],
|
|
629
|
+
[{ threads: [thread] }, { kind: "review-threads" }],
|
|
630
|
+
[
|
|
631
|
+
{ facts: { reviewDecision: "REVIEW_REQUIRED" } },
|
|
632
|
+
{ kind: "merge-gate", reason: "review-required" },
|
|
633
|
+
],
|
|
634
|
+
[
|
|
635
|
+
{ facts: { mergeStateStatus: "BLOCKED" } },
|
|
636
|
+
{ kind: "merge-gate", reason: "merge-blocked" },
|
|
637
|
+
],
|
|
638
|
+
[
|
|
639
|
+
{ facts: { isDraft: true } },
|
|
640
|
+
{ kind: "merge-gate", reason: "draft-pr" },
|
|
641
|
+
],
|
|
642
|
+
] as const;
|
|
643
|
+
for (const [overrides, blocker] of cases)
|
|
644
|
+
expect(classifyPr(await read(overrides))).toMatchObject({
|
|
645
|
+
kind: "blocker",
|
|
646
|
+
blocker,
|
|
647
|
+
});
|
|
648
|
+
});
|
|
649
|
+
|
|
650
|
+
it("fails closed while the head may not have reported yet", async () => {
|
|
651
|
+
const unsettled = [
|
|
652
|
+
{
|
|
653
|
+
commitRollups: [
|
|
654
|
+
{ oid: "earlier", state: "SUCCESS" },
|
|
655
|
+
{ oid: "head", state: null },
|
|
656
|
+
],
|
|
657
|
+
},
|
|
658
|
+
{ commitRollups: [{ oid: "head", state: "PENDING" }] },
|
|
659
|
+
{ facts: { mergeable: "UNKNOWN", mergeStateStatus: "UNKNOWN" } },
|
|
660
|
+
] as const;
|
|
661
|
+
for (const overrides of unsettled)
|
|
662
|
+
await expect(read(overrides)).rejects.toMatchObject({
|
|
663
|
+
failure: { kind: "checks-unavailable", retryable: true },
|
|
664
|
+
});
|
|
665
|
+
});
|
|
666
|
+
|
|
667
|
+
it("names the absence of checks in the status table and the READY verdict", async () => {
|
|
668
|
+
const reader = () =>
|
|
669
|
+
fakeReader({ ...noChecks, facts: { reviewDecision: null } });
|
|
670
|
+
const status = testRuntime(reader());
|
|
671
|
+
expect(
|
|
672
|
+
await main([...single, "--pretty", "--status-only"], status.runtime)
|
|
673
|
+
).toBe(0);
|
|
674
|
+
expect(status.stdout.join("")).toContain(
|
|
675
|
+
"| [#1](https://github.com/owner/repo/pull/1) | ➖ no checks | ✅ | ✅ |"
|
|
676
|
+
);
|
|
677
|
+
const ready = testRuntime(reader());
|
|
678
|
+
expect(await main([...single, "--pretty"], ready.runtime)).toBe(0);
|
|
679
|
+
expect(ready.stdout.join("")).toBe(
|
|
680
|
+
"READY: no merge conflicts, no unresolved review threads, no failing or pending checks\nmergeStateStatus=CLEAN\nreviewDecision=null\nisDraft=false\nchecks=none reported on the head commit\n"
|
|
681
|
+
);
|
|
682
|
+
});
|
|
683
|
+
});
|
|
684
|
+
|
|
685
|
+
// These replay through the real gh reader what gh returned for a mergeable PR
|
|
686
|
+
// in a repository with no checks configured: `gh pr checks` exits 1 with "no
|
|
687
|
+
// checks reported" and the head commit's statusCheckRollup is null.
|
|
688
|
+
describe("the gh reader on a repository with no checks configured", () => {
|
|
689
|
+
const directories: string[] = [];
|
|
690
|
+
afterEach(() => {
|
|
691
|
+
for (const dir of directories.splice(0))
|
|
692
|
+
rmSync(dir, { recursive: true, force: true });
|
|
693
|
+
});
|
|
694
|
+
|
|
695
|
+
function run(scenario: string, extra: readonly string[]) {
|
|
696
|
+
const dir = mkdtempSync(join(tmpdir(), "watch-no-ci-"));
|
|
697
|
+
directories.push(dir);
|
|
698
|
+
const bin = join(dir, "bin");
|
|
699
|
+
mkdirSync(bin);
|
|
700
|
+
const gh = join(bin, "gh");
|
|
701
|
+
writeFileSync(
|
|
702
|
+
gh,
|
|
703
|
+
`#!${process.execPath}
|
|
704
|
+
const args = process.argv.slice(2);
|
|
705
|
+
const scenario = process.env.WATCH_FIXTURE;
|
|
706
|
+
const fail = (stderr) => { console.error(stderr); process.exit(1); };
|
|
707
|
+
const graphql = (name) => args.some((a) => a.includes('query ' + name));
|
|
708
|
+
const commits = (commit) => ({ data: { repository: { pullRequest: { commits: { nodes: [{ commit }] } } } } });
|
|
709
|
+
let value;
|
|
710
|
+
if (args[0] === 'pr' && args[1] === 'view') {
|
|
711
|
+
value = { mergeable: 'MERGEABLE', mergeStateStatus: scenario === 'blocked' ? 'BLOCKED' : 'CLEAN', reviewDecision: '', headRefOid: 'head', headRefName: 'feature', baseRefName: 'main', state: 'OPEN', mergedAt: null, isDraft: false };
|
|
712
|
+
} else if (args[0] === 'pr' && args[1] === 'checks') {
|
|
713
|
+
if (scenario === 'unauthorized') fail('HTTP 401: Bad credentials (https://api.github.com/graphql)');
|
|
714
|
+
fail("no checks reported on the 'feature' branch");
|
|
715
|
+
} else if (graphql('PrCheckRollup')) {
|
|
716
|
+
if (scenario === 'rollup-fails') fail('HTTP 502: Bad Gateway (https://api.github.com/graphql)');
|
|
717
|
+
value = commits({ statusCheckRollup: null });
|
|
718
|
+
} else if (graphql('PrCommitStatuses')) {
|
|
719
|
+
value = commits({ oid: 'head', statusCheckRollup: null });
|
|
720
|
+
} else if (graphql('ReviewThreads')) {
|
|
721
|
+
value = { data: { repository: { pullRequest: { reviewThreads: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } } } } } };
|
|
722
|
+
} else {
|
|
723
|
+
fail('unexpected fixture command: ' + JSON.stringify(args));
|
|
724
|
+
}
|
|
725
|
+
console.log(JSON.stringify(value));
|
|
726
|
+
`
|
|
727
|
+
);
|
|
728
|
+
chmodSync(gh, 0o755);
|
|
729
|
+
const entry = join(dir, "entry.ts");
|
|
730
|
+
writeFileSync(
|
|
731
|
+
entry,
|
|
732
|
+
`import { main } from ${JSON.stringify(join(import.meta.dirname, "cli.ts"))}; process.exitCode = await main(process.argv.slice(2));\n`
|
|
733
|
+
);
|
|
734
|
+
const result = spawnSync(
|
|
735
|
+
process.execPath,
|
|
736
|
+
[entry, ...single, "--max-query-errors", "1", ...extra],
|
|
737
|
+
{
|
|
738
|
+
encoding: "utf8",
|
|
739
|
+
timeout: 10_000,
|
|
740
|
+
env: { PATH: `${bin}:${process.env.PATH}`, WATCH_FIXTURE: scenario },
|
|
741
|
+
}
|
|
742
|
+
);
|
|
743
|
+
return {
|
|
744
|
+
status: result.status,
|
|
745
|
+
verdicts: result.stdout
|
|
746
|
+
.trim()
|
|
747
|
+
.split("\n")
|
|
748
|
+
.map((line) => JSON.parse(line) as unknown),
|
|
749
|
+
};
|
|
750
|
+
}
|
|
751
|
+
|
|
752
|
+
it("finishes a status-only pass", () => {
|
|
753
|
+
expect(run("clean", ["--status-only"])).toMatchObject({
|
|
754
|
+
status: 0,
|
|
755
|
+
verdicts: [
|
|
756
|
+
{
|
|
757
|
+
kind: "STATUS",
|
|
758
|
+
terminal: true,
|
|
759
|
+
rows: [{ kind: "open", ci: { kind: "ci-none" } }],
|
|
760
|
+
},
|
|
761
|
+
],
|
|
762
|
+
});
|
|
763
|
+
});
|
|
764
|
+
|
|
765
|
+
it("reports a clean PR as READY", () => {
|
|
766
|
+
expect(run("clean", [])).toMatchObject({
|
|
767
|
+
status: 0,
|
|
768
|
+
verdicts: [
|
|
769
|
+
{
|
|
770
|
+
kind: "READY",
|
|
771
|
+
scope: {
|
|
772
|
+
pr: { kind: "ready-pr", proof: { ci: { kind: "ci-none" } } },
|
|
773
|
+
},
|
|
774
|
+
},
|
|
775
|
+
],
|
|
776
|
+
});
|
|
777
|
+
});
|
|
778
|
+
|
|
779
|
+
it("does not stop at the merge gate on the first read of a blocked PR", () => {
|
|
780
|
+
expect(run("blocked", ["--timeout", "0.001"])).toMatchObject({
|
|
781
|
+
status: 5,
|
|
782
|
+
verdicts: [
|
|
783
|
+
{ kind: "WAITING", reason: { kind: "confirming-block" } },
|
|
784
|
+
{ kind: "TIMEOUT", reason: { kind: "confirming-block" } },
|
|
785
|
+
],
|
|
786
|
+
});
|
|
787
|
+
});
|
|
788
|
+
|
|
789
|
+
it("fails closed when a check query fails instead of reporting no checks", () => {
|
|
790
|
+
for (const scenario of ["unauthorized", "rollup-fails"])
|
|
791
|
+
expect(run(scenario, ["--status-only"])).toMatchObject({
|
|
792
|
+
status: 7,
|
|
793
|
+
verdicts: [{ kind: "BLOCKER", blocker: { kind: "status-query" } }],
|
|
794
|
+
});
|
|
795
|
+
});
|
|
796
|
+
});
|