mirror of
https://github.com/DeusData/codebase-memory-mcp.git
synced 2026-11-09 09:11:00 +08:00
cppcheck blocked the release run, correctly: src/main.c:283: Condition '!main_test_worker_project_lock_marker(mutation)' is always false src/main.c:2049: Condition '!worker_start_watchdog_test_descendant()' is always false Compiling the seams out left behind stubs that returned true unconditionally, so negating them was provably constant. Refactored rather than suppressed (repo rule): the stubs are deleted and the CALL SITES are guarded, so a release build does not contain the call at all -- which is what "the seam is not in the artifact" should have meant in the first place. The worker path needed care. The probe was one term in a five-term `||` chain, and its POSITION is load-bearing: it must fork AFTER the isolated process group exists (it inherits that group) and BEFORE the parent-death watchdog thread starts, because forking a multithreaded process is the bug that ordering avoids. Hoisting the call out of the chain would compile, pass tests, and silently break that invariant. So the chain is split into three ordered steps -- process group, then (test builds only) the probe, then the watchdog -- sharing one worker_containment_unavailable() failure path so every step still fails identically, with write()/_exit() rather than stdio and atexit handlers. Verified in BOTH directions, since a guard that is always off is as wrong as one always on: a TEST_SEAMS=1 build still contains the probe and tests/test_worker_watchdog.sh passes against it, while the release build carries no seam string. `make -f Makefile.cbm lint-ci` now passes locally -- the step skipped before the last push, and the reason CI found this instead of me. Signed-off-by: Martin Vogel <martin.vogel.tech@gmail.com>