Skip to content

fix(bin): distinguish validation handoff from terminal completion - #2958

Open
connectwithclayton wants to merge 1 commit into
kunchenguid:mainfrom
connectwithclayton:fm/fm-brief-done-wording
Open

connectwithclayton wants to merge 1 commit into
kunchenguid:mainfrom
connectwithclayton:fm/fm-brief-done-wording

Conversation

@connectwithclayton

Copy link
Copy Markdown

What changed

  • Generated no-mistakes briefs now use needs-validation: {summary} for the committed implementation handoff and reserve done: PR {url} checks green for terminal completion.
  • Centralized status classification treats the new marker as actionable and non-terminal, so supervisors can distinguish the two states by verb alone.
  • Supervision keeps the two-phase flow intact: workers still stop after the implementation commit, and firstmate still triggers validation before the terminal PR completion report.

Defect

Worker instructions reused the done: prefix for both "implementation committed, start validation" and "PR open, checks green, finished."
A supervisor reading a status log therefore could not distinguish the opposite lifecycle states mechanically.

Before, both states appeared as done::

  • done: implementation committed
  • done: PR https://example.test/pr/7 checks green

After, the handoff and terminal state are distinct:

  • needs-validation: implementation committed
  • done: PR https://example.test/pr/7 checks green

Validation

At shipping head 3db189f8, the test phase reported:

Targeted behavioral suites and an end-to-end generator/classifier transcript completed successfully, proving the worker handoff remains non-terminal, active validation supersedes the handoff, terminal PR completion remains done:, and heartbeat fail-safe behavior remains covered; lint was intentionally not run under the test-phase prohibition.

The outer lint phase subsequently ran bin/fm-lint.sh successfully with pinned ShellCheck 0.11.0 and actionlint 1.7.12.

@greptile-apps

greptile-apps Bot commented Aug 24, 2026 •

Copy link
Copy Markdown

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains; the previously reported legacy FM_CAPTAIN_RE override path now recognizes the validation handoff before applying the override regex.

Reviews (2): Last reviewed commit: "fix(classify): preserve validation hando..." | Re-trigger Greptile

Comment thread bin/fm-classify-lib.sh Resolved
@connectwithclayton

Copy link
Copy Markdown
Author

Addressed the review finding in 1afa3dc. status_is_captain_relevant now recognizes the configured needs-validation handoff before applying FM_CAPTAIN_RE, so a legacy operator regex cannot silently suppress the validation trigger; regression coverage includes both a realistic legacy regex and an overridden handoff verb. I audited every vocabulary consumer: watcher, daemon, stale and signal scans, and push-transition handling all route through the shared classifier, so no other override-blind path remains. Full local runner on the exact committed tree contents: FM_TEST_SUMMARY total=160 failed=12 skipped_gate=27 duration_ms=6472283; all changed-path tests and lint passed, while the 12 failures were unrelated existing baseline cases.

@kunchenguid

Copy link
Copy Markdown
Owner

Speaking as Kun's firstmate: triage for #2958 (connectwithclayton, fix(bin): distinguish validation handoff from terminal completion).

Classification: new-default (tip vs main 4812db801628040b609dc25a2a8a91ed5efac662…27fdd55c07ff7dcbcf5b8284d0632c49130ce799). Tip introduces default classifier/brief verb needs-validation: and replaces main's specified no-mistakes DoD handoff (done: {summary} after implementation commit) with that new verb across bin/fm-brief.sh, bin/fm-dod-lib.sh, bin/fm-classify-lib.sh, and related consumers. Main has no needs-validation / NEEDS_VALIDATION symbols. Replacing the specified default path is new-default; "bugfix" / distinguishability framing does not make restore. Related theme to open #4892 (completion-evidence wording within done:) but different contract — not a duplicate.

VISION (per-rule, inspected evidence):

  • One captain, one interface — aligns (clearer handoff vs terminal for supervisors). Evidence: status_is_validation_handoff + brief STATUS_STATES split.
  • Authority explicit — aligns (no new merge/autonomy grant). Evidence: vocabulary/classifier/brief only; FM_CAPTAIN_RE cannot suppress the handoff verb.
  • Scripts own mechanics — aligns. Evidence: deterministic classifier helpers + generated brief verbs; tests in tests/fm-*.test.sh.
  • Restart is a non-event — aligns (status-line contract only). Evidence: no durable-record format break beyond status verb.
  • Delegation with a spine — aligns (sharpens no-mistakes two-phase spine). Evidence: DoD + AGENTS Validate wording.
  • Fleet outlives any vendor — aligns. Evidence: no vendor/UI coupling.
  • Scope — aligns (command-layer status contract). Evidence: bin + docs + tests; workflow-zero.

Attestation: missing (no no-mistakes-pipeline-attestation:v1 block on the PR body). Author needs a matching attestation for HEAD 27fdd55c07ff7dcbcf5b8284d0632c49130ce799.

Security / fishy: none blocking. Greptile P1 on legacy FM_CAPTAIN_RE dropping the handoff was addressed in-thread (handoff recognized before override). No workflow files. First-time fork CI approved this pass: CI 35425309615, NM 35425309583 (queued).

Gates: MERGEABLE / UNSTABLE (ahead 1 / behind 1). No auto-merge (new-default + attestation missing). Not otherwise ready — not escalating.

Decision: waiting-author for pipeline attestation on current HEAD (and rebase onto main when convenient); CI running after workflow approval.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants