---
name: spt-verification-gates
description: "Pre-\"done\" gates for spt-core waves — workspace clippy form, real-binary rebuild, real-terminal verify, shared-tree hygiene"
metadata: 
  node_type: memory
  type: feedback
  originSessionId: 73618172-412e-4954-b8aa-e2c8955dfd49
---

Before declaring an spt-core wave/fix done (doyle gates each wave), pass these — `cargo build` and per-crate clippy are NOT enough:

1. **EXACT CI clippy form:** `cargo clippy --workspace --all-targets -- -D warnings`. A per-crate `cargo clippy -p spt` or a `cargo build` MISSES workspace lints — e.g. adding a param pushed `establish_perch` to 8 args → `clippy::too_many_arguments` → CI red, invisible to build. Run the workspace form before "done."
2. **`cargo test`/`clippy` ≠ rebuilding the installed binary.** They build the lib + test targets, not `target\debug\spt.exe`. To verify/ship the REAL binary (e.g. an operator capture): `cargo build -p spt --bin spt`. Never clobber a running daemon's `spt.exe` (Windows file lock) — daemon stop or the release path.
3. **Terminal-input fixes must be verified on the REAL terminal** (operator HITL re-capture). Unit/clippy never exercise the live key path — the W7 VT-input fix passed unit+clippy but backfired live (Windows Terminal → win32-input-mode, broke ctrl-b detach).
4. **The working tree is SHARED** with doyle/CI/operator. Never leave it mid-edit — commit/park, or do WIP in a `git worktree`. `cfg(test)`/`tests/` edits are build-excluded (safe); only non-test impl mid-edit breaks others' builds.

**Why:** all four are real misses this session (doyle caught 1–4). **How to apply:** run gate 1 + (for binary-facing changes) gate 2 before pinging doyle a wave is done; gate 3 for any rc/terminal change; gate 4 always. See [[delegate-tests-to-spt-test-engineer]] for who writes the tests.
