--- id: "bug-1605" status: "cannot-reproduce" status_updated: "2026-09-24" status_note: "transient build failure, passed on immediate retry; likely bug-1604 collision" component: "lib" severity: "unknown" timestamp: "2026-08-20T10:27:00.000Z" last_seen: "2026-09-19T09:00:00Z" occurrences: 1 files: ["src/lib/controller.capnp.c (generated)", "src/controller/config_repl.c (consumer)"] tags: ["build", "capnp", "codegen", "concurrent-build-collision", "controller", "needs-followup", "ninja", "pre-existing", "race", "transient"] related: ["bug-1439", "bug-1493", "bug-1604"] repro_attempts: "1 retry, clean" legacy: true --- # bug-1605: controller ASAN build: two failures in the same ninja run -- (1) controller/config_repl.c:1921:28… ## Description controller ASAN build: two failures in the same ninja run -- (1) controller/config_repl.c:1921:28: error: 'RequestReply_data_probeconfigtagreplymsg' undeclared (first use in this function); did you mean 'RequestReply_data_upgradeconfigreplymsg' -- and (2) lib/controller.capnp.c:25013:1: fatal error: opening dependency file lib/libxce.a.p/meson-generated_.._controller.capnp.c.o.d: No such file or directory, compilation terminated; ninja: build stopped: subcommand failed. ## Environment _Not recorded (migrated from buglog.json)._ ## Reproduction - Attempts: 1 retry, clean ## Root cause Matches the capnp custom_target's documented missing-dependency-edge race (see comment block at top of src/tools/xce-build.sh, 'retry once before debugging'): config_repl.c was compiled against a stale/partially-regenerated controller.capnp.h that lacked the 'probeconfigtagreplymsg' enumerant even though src/schema/controller.capnp:596 defines it (probeconfigtagreplymsg @20: ProbeConfigTagReply), and lib/controller.capnp.c's own compile then hit an I/O race writing its .d dependency file, most likely because the generator custom_target re-ran/rewrote lib/ mid-build without ninja having a correct dependency edge ordering the two. Not caused by the concurrent main.c/testsuite/test.c argp_program_version diff (those files are unrelated to config_repl.c/capnp). CORRECTION (same session, minutes later): discovered via `ps aux` a THIRD live instance of a concurrent `nix develop ./src --command bash src/tools/xce-build.sh controller asan` process actively doing rm -rf xce.build + fresh meson compile in this SAME shared worktree at 10:38, i.e. immediately after this bug's own two build attempts (10:23-10:33) -- and .wolf/memory.md/cerebrum.md already documented an earlier occurrence THIS SAME SESSION of exactly this hazard (bug-1604: two concurrent xce-build.sh runs sharing default BUILD_DIR=xce.build race on rm -rf, one silently wiping/regenerating the other's in-progress build, corrupting or vanishing already-verified binaries). The 'known capnp codegen dependency-edge race' explanation above is therefore NOT confirmed as the true root cause -- a concurrent cross-session xce-build.sh collision (bug-1604) is at least as likely, and possibly the actual cause, of both the stale-header undeclared-enum error and the .d-file open I/O failure (a concurrent rm -rf mid-compile would produce exactly both symptoms). Do not treat this entry as proof the capnp custom_target race is real without ruling out concurrent-session collision first -- check `ps aux | grep xce-build.sh` before attributing a build failure to codegen internals in this worktree. ## Fix Confirmed transient: re-ran the exact same command (nix develop ./src --command bash src/tools/xce-build.sh controller asan) a second time with zero source changes in between and the full clean build compiled successfully (202/202, zero errors). Not root-caused/fixed in the underlying capnp custom_target dependency graph -- xce-build.sh's own comments already document this as a known, unfixed gap and recommend exactly this retry-once workaround. ## Verification _Not recorded (migrated from buglog.json)._ ## References - Related: bug-1439, bug-1493, bug-1604