{
  "summary": "Existing real Windows recipe is dummy_harness_e2e: isolated `spt daemon run` → registered dummyharness → endpoint create/start → actual piped `spt rc`. It supplies a real ConPTY counter, not a mocked client. Dummy fixture does NOT consume/acknowledge input or emit producer timestamps; receiver timestamps are straightforward, but a combined timestamp/echo generator is an additional Main-owned rig prerequisite. No commands, builds, tests, edits, or live service calls executed.",
  "files": [
    {
      "path": "crates/spt/tests/dummy_harness_e2e.rs:78-223",
      "description": "Complete real daemon + adapter registration + endpoint bringup + actual rc subprocess recipe; net-enabled requirement, piped stdin held open."
    },
    {
      "path": "adapters/mock/src/main.rs:118-235",
      "description": "mock-session dummy binds through actual spt api then emits flushed DUMMY_HARNESS_TICK:<id>:<counter>; no input-reading loop or producer timestamps."
    },
    {
      "path": "crates/spt/tests/common/mod.rs:21-47",
      "description": "Exact endpoint mint command; create and start are separate."
    },
    {
      "path": "crates/spt/tests/common/reap.rs:39-177",
      "description": "ProcObservation, observe, same_image, authenticated_kill; PID/birth/image/self/ancestry checks. population_sweep at 352-446 provides survivor accounting."
    },
    {
      "path": "crates/spt/src/rc.rs:1560-1605,2260-2315",
      "description": "Windows redirected stdin uses real raw-byte input reader; actual attach and pump; output capture without interactive display guard."
    },
    {
      "path": "crates/spt-daemon/src/endpoint.rs:1-100",
      "description": "SPT_HOME-derived broker/seed socket names, daemon.pid and brain.ready semantics."
    },
    {
      "path": "crates/spt-daemon/src/daemon.rs:522-565",
      "description": "Production net initialization: durable isolated node identity, configured relay, mDNS, all interfaces, membership; NET_BIND_FAIL yields net-less broker."
    },
    {
      "path": "crates/spt/src/cli.rs:8691-8717",
      "description": "SPT_RC_HITCH_DIAG probe command, 2s split-pump IO timeout, query_elapsed_ms and error result."
    },
    {
      "path": "crates/spt-daemon/src/broker.rs:9290-9303",
      "description": "Exact hitch probe fields and lock-light sampling."
    },
    {
      "path": "crates/spt-daemon/src/nethost.rs:1384-1395,1545-1550",
      "description": "25ms runtime canary; small age roughly below 100ms means runtime scheduling normally."
    },
    {
      "path": "crates/spt-daemon/tests/broker.rs:39-146",
      "description": "Actual native IPC spawn/input/kill recipe with Windows findstr echo child."
    },
    {
      "path": "crates/spt/tests/resume_no_control_steal_e2e.rs:128-163",
      "description": "Windows Powershell periodic TICK SpawnReq generator."
    },
    {
      "path": ".spt/preserved/302/rc_hitch_diag_smoke.rs",
      "description": "Retained actual CLI diagnostic smoke with loopback NetHost and net-less/absent comparisons; NOT an rc/PT Y/brain rig."
    },
    {
      "path": ".spt/preserved/302/RUNBOOK-five-lines.txt",
      "description": "Cadence A/B recipe: backup, all three periods=600000, refresh, settle/observe ~2min, byte restore/refresh."
    },
    {
      "path": ".spt/preserved/302/HANDOFF.txt",
      "description": "Retained prior observation: healthy loopback canary 18ms/zero dials, net-less null, absent probe_error; old resident image unsupported. Historical only."
    }
  ],
  "architecture": "Broker owns ConPTY; supervised brain coordinates endpoint lifecycle. Local rc is the real network-stream attach path using a broker-minted loopback connection, so NetHost must exist even on one machine. The isolated home determines IPC rendezvous. Piped rc input exercises the actual attach pump but not interactive Windows console KEY_EVENT translation or terminal rendering.",
  "report": "CALLABLE EXISTING RECIPE (source-backed, not executed here)\n1. Main builds pinned worktree into its own target: `cargo build --manifest-path <worktree>/Cargo.toml --target-dir <owned-target> -p spt --bin spt` and `cargo build --manifest-path <worktree>/Cargo.toml --target-dir <owned-target> -p mock-adapter --bin mock-session`. Workspace member is adapters/mock, not crates/mock-adapter. Use absolute resulting executables throughout; do not resolve resident `spt` through PATH.\n2. Every child gets the SAME explicit absolute fresh `SPT_HOME`; sanitize inherited SPT_*, OWL_*, CLAUDE_* first, then add permitted rig variables. Retained smoke also sets TMP/TEMP to the fresh home and SPT_INSTALL_NO_FIREWALL=1. Add SPT_TEST_EPHEMERAL_ADVISORY_PORTS=1 for daemon children (docshost.rs:94; current real-daemon tests use it so resident advisory ports are not occupied). Do not merely set a shell-global home and trust descendants accidentally inherit it. No manual socket override needed or identified: endpoint.rs hashes the active spt_home PathBuf with DefaultHasher into `spt-daemon-broker-<16hex>.sock` and analogous seed name. Keep exact home spelling consistent across all children; use library broker_socket_name()/seed_socket_name(), not an independently guessed hash.\n3. Reuse dummy_harness_e2e.rs:100-130 fixture under fresh home's srcs/dummyharness. Manifest fields: `[adapter] name=\"dummyharness\", kind=\"harness\", version=\"1\", min_spt_core_version=\"0\"`; `[session.self] command='<absolute-mock-session> --mode dummy --id {id} --session-id {session_id} --spt <absolute-spt> --mock-adapter dummyharness --type live_agent --heartbeat-ms 200'`; `[session] commune_dir` and `signoff_dir` point to fresh drops dir; `[session.psyche_init] command='psychebin ready {id}', cwd='{psyche_dir}', keys=[]`. Existing recipe stages a copy of owned spt as srcs/dummyharness/psychebin.exe. Paths in command template are normalized to forward slashes by test. Existing tested registration API is `spt_runtime::registry::register(&spt_store::perch::adapters_dir(), &src, 1000)` under isolated process home. CLI alternative is `spt adapter add <src>` (cli.rs:1425-1433); API avoids CLI post-registration activity.\n4. Launch owned `<spt> daemon run` with explicit isolation, captured stderr and owned Child handle. Test waits up to 30s for `<home>/brain.ready` JSON pid, then runs `<spt> endpoint create <id> --adapter dummyharness` and `<spt> endpoint start <id>`. Endpoint helper bounds create at 45s; test bounds start at 45s and checks online up to 20s. Require successful statuses, not merely matching output. PTY child pid comes from actual ENDPOINT_RUN token `pid=...`; the test warns info.json pid can instead be transient api-bind subprocess.\n5. Launch `<spt> rc <id>` with stdin/stdout pipes and stderr file. Hold stdin writer OPEN for entire observation. Spawn output reader concurrently; timestamp each received chunk/parsed counter using monotonic time and wall-clock epoch. Set SPT_PUMP_TRACE=1 only with stderr captured if construction proof desired. Source counter `DUMMY_HARNESS_TICK:<id>:<n>` is flushed every 200ms. Write input bytes to actual rc stdin and flush, e.g. unique tagged line ending CR; detach with bytes 0x02,0x64 (Ctrl-B then d), which must not kill the endpoint. Pipes exercise the real spt client and broker PTY, not a mocked status/client, but do NOT prove interactive KEY_EVENT behavior or visible terminal freezes.\n\nGENERATOR LIMIT / NATIVE ALTERNATIVE\nThe retained dummy emits counters only; `--mode echo` elsewhere reads stdin to EOF and exits, so it is NOT the desired live echo companion. No retained all-in-one counter+producer-timestamp+input-ack generator was found. Main can already collect receiver timestamps unattended; actual input processing latency needs an additional disposable generator or a second existing findstr echo session. Do not mistake ConPTY local echo for application acknowledgement.\nExisting wire/API source for arbitrary generator: `LocalSocketTransport::connect(&broker_socket_name())`; `send_hello(&mut conn, Role::Brain)`; `write_frame(&mut conn, &Envelope::new(KIND_SPAWN, serde_json::to_value(SpawnReq{program,args,rows:24,cols:80,endpoint:<id>,cwd:None,env:...,translation_binary:None,adapter:...,install_dir:None})))`; read frames until KIND_SPAWNED, retaining interleaved KIND_OUTPUT, then use returned session_id. broker.rs integration uses Windows `program=\"findstr\", args=[\".\"]` for echo; resume_no_control_steal_e2e uses `program=\"powershell\", args=[\"-NoProfile\",\"-NonInteractive\",\"-Command\",\"while ($true) { [Console]::Out.WriteLine('TICK'); Start-Sleep -Milliseconds 150 }\"]` for periodic output. InputReq shape is `{session_id,data_b64:encode_bytes(b\"TAG\\r\"),op_id:None,minter:None,ack:true}` via KIND_INPUT. KillReq `{session_id}` via KIND_KILL, read KIND_EXIT. These prove raw spawning/IO, not registered endpoint resolution by themselves; prefer endpoint-start fixture for brain-coordinated lifecycle. Native JSON codec is 4-byte BIG-ENDIAN length then UTF-8 Envelope JSON (`protocol_version=1`, kind, payload), maximum 16MiB; use library send_hello rather than inventing an initial frame. Windows named-pipe Whole streams reject read timeouts; use split-pump/deadline API or externally bounded readers.\n\nCANARY / REAL NETWORK\nDo NOT replace the production daemon with the retained net-less broker smoke. `spt daemon run` initializes real NetHost with isolated durable node key, configured relay, mDNS, all interfaces and production membership. NET_BIND_FAIL means it may initially serve net-less and retry. Admission to measurement requires probe `net_enabled=true` AND numeric net_canary_age_ms; failed/unsupported/absent probe is not a null healthy result. Zero active_dial_tasks is a valid healthy idle value, not grounds to synthesize pending traffic. Explicit loopback-only NetHost (`identity=Identity::generate(),relay=Disabled,discovery=Off,scope=Loopback,membership=None`) in retained helper gives a genuine non-null runtime canary, but changes networking conditions and omits real brain workload; use only for instrument capability, not field equivalence.\nProbe command is owned `<spt> node status --json` with child-only `SPT_RC_HITCH_DIAG=1` and same isolated home. Fields: diagnostic='rc-hitch', broker_pid, broker_version, sampled_at_ms, net_enabled, net_canary_age_ms, active_dial_tasks; CLI adds query_elapsed_ms. Failure gives diagnostic/probe_error/query_elapsed_ms and exit 1. Check broker_pid equals held daemon Child identity before accepting sample. Canary stamps every 25ms; source documents age <~100ms as healthy scheduling. Capture query latency separately so delayed IPC is not mistaken for old reactor stamp.\n\nIDENTITY / TEARDOWN GUARD\nUse common/reap.rs observe() immediately while daemon, brain and harness are provably owned; retain pid+started_at, image paths and parent relation. brain.ready is only a breadcrumb, not identity/liveness. Require process_identity(pid)=Present(original_started_at), exe_path same as owned target, correct ancestry, and exclusion of observer/self/ancestors AND resident inventory before mutations. authenticated_kill supports creation-time comparison only when given Some(ProcObservation); this assignment must not accept its weaker None fallback. population_sweep scopes by owned staged image root plus identity-pinned seed ancestry; unreadable is unknown, not gone. The older dummy_harness_e2e local kill_pid(taskkill /T) helper is UNSAFE for this stronger assignment; reuse authenticated seam instead. Derive isolated socket, record it, connect only through that home, and verify live probe broker_pid against held process before endpoint lifecycle/refresh. Existing endpoint/process APIs remain subject to Main's 300s observation +120s teardown limits; do not copy older tests' unconditional PID kills.\n\nCADENCE / NO-REPRO EVIDENCE\nFive-line retained flow: exact daemon.json backup; change only notif_pump_period_ms, registry_pump_period_ms, sync_pull_period_ms to 600000; owned-home node refresh and require success; let priming settle, observe ~2min; restore exact original bytes and refresh successfully, compare both arms. NEVER execute retained runbook's resident default-home fallback. Here this is authorized only on fresh owned home. Refresh retains broker/PTY/net runtime; wake-triggered rounds remain possible. Disappearance and return supports pump-round class, not candidate #1 vs #2. Healthy baseline/no reproduction is valuable without any cadence edit: keep production defaults and workload unchanged, record uninterrupted counter arrivals, actual input ack if generator supports it, numeric fresh canary, probe timing and dials. Conclude only 'no hitch observed in this isolated local workload/window'; fresh home lacks resident peer/dead-peer workload and cannot exonerate field behavior. Do not fabricate pending update state, dead peers, or stress load to force a finding. Existing source supports a working counter + actual rc rig now; combined producer timestamp/echo fixture and any interactive-console evidence remain explicit missing rig prerequisites, not already proven capabilities."
}
