1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
// Engine code is fully exercised by the default (server) build, where dead-code
// checking stays on. In `embed` builds an embedder uses only a subset of the
// engine API, so unused-but-public engine helpers are expected — not dead.
// ── Engine: always compiled (parsing + live_index + query + git + shared base) ──
// Feature 020 V11 identity minting, shared by the dark lifecycle runtime and the
// protocol provenance types so both draw from ONE process-wide counter.
//
// `pub(crate)` is load-bearing, not a style choice: the frozen public-API census
// adds one atom per `pub mod NAME;` line in THIS file, so a plain `pub mod` here
// would widen a surface Slice 3 must leave frozen. Modules that expose one of
// these types publicly re-export it instead.
pub
// Feature 020 V11, D4, amended by the C2 ruling (2026-08-14): the REAL
// server_api module, flip-ready. TWO gates are load-bearing: `pub(crate)`
// keeps it out of the census until activation flips that one keyword, and
// the `cfg(feature = "server")` matches the frozen contract's availability
// column — the embed-v11 projection EXCLUDES this module, so embed cells
// must never grow its four atoms. D4's earlier "std-only so the embed build
// compiles it unused" sentence is amended: std-only stays true, but the
// module no longer compiles under embed at all. No `pub use` anywhere; no
// call edge into index_lifecycle. Do NOT "tidy" either gate before the cut.
pub
// Watcher state snapshot types (data only) — used by engine health stats; the
// notify-based watcher runtime lives in the server-gated `watcher` module.
// Engine-adjacent helpers (no server deps); used by the engine and the server.
// ── Protocol-free STEL storage + calibration seam (D3-ROOT extract-up) ──
// The durable economics ledger + calibration math are pure STORAGE + MATH with
// no transport/protocol dependency, so they compile under BOTH the full server
// build AND the engine-only `embed` facade — delivering FR-001 embed
// durability. The server-only `stel` module re-exports these submodules so
// every existing `crate::stel::{types,ledger_store,calibration}` caller path
// resolves unchanged. Gated `any(server, embed)`: dead under neither, so no
// false embed-capability signal (unlike a bare `any(...)` on a server-coupled
// module).
// ── Server surface: excluded from `--no-default-features --features embed` ──
// daemon/sidecar/protocol-server/CLI + their heavy deps (axum, rmcp, clap,
// reqwest, notify, tracing-subscriber). Library embedders never compile these.
// Proactive PATH-shadow detection: warns when a bare `symforge` resolves to a
// different (stale) install than the one we believe we are. Used by cli::init,
// cli::update, and protocol health — all server-only.
// Console-flash-free child spawning (CREATE_NO_WINDOW on Windows); used by the
// daemon's helper spawns, worktree listing, PATH-shadow probes, and the updater.
// NOT server-gated: std-only, and embed-cfg'd test code in git/store/discovery
// spawns git through it (the embed --lib test build compiles those modules).
// public so integration tests share the no-console spawn helper
// Transport-agnostic operator server spine (v8): `symforge serve` over /mcp.
// Worktree routing hooks into the protocol edit registry — server-only.
// ── Engine-only facade for library embedders (e.g. AAP) ──