gate:dataflow: gitignored build residue under core/<dom>/src is not an unregistered module — gates.mjs all runs twice in one worktree (#1657) - #1658
Conversation
…walkDirs() gate:dataflow requires every directory under a src-laid-out domain's src/, and its listing never consulted skippable(). Any pytest gate run in core/flows compiles core/flows/src/*.py into core/flows/src/__pycache__/, so the next dataflow run — and gate:arch-report, which re-runs it — redded on gitignored bytecode as an unregistered module: `gates.mjs all` could not be run twice in one worktree, and the pre-push hook's fast subset carries dataflow, so the residue blocked pushes. lsdirs now filters with skippable() before the isDirectory test, and skippable() recognises *.egg-info alongside the dot-dirs and the SKIP set — the residue .gitignore already keeps out of the tree — so every walkDirs() user closes the same hole at once. Regression rows in scripts/gates.test.mjs plant __pycache__, .venv and an *.egg-info under core/flows/src (green) and a real-looking package in the same place (RED, named by path): the population is narrowed to modules, the anti-drift guard is not disarmed. Delivers #1657. Signed-off-by: DmitriyG228 <2280905@gmail.com>
🃏 Merge card — #1658
Not mergeable yet — every row above must be accepted before merge (choke point 1). Fill in what's ❌ above, then this clears automatically. How a PR reaches merge: the merge bar. |
|
The line, measured. |
Delivers issue: #1657
Contribution rights
under Apache-2.0, and it is not owned or controlled by an employer, client, or other entity.
may control this contribution. I am requesting Vexa's private corporate-authorization process.
Observation bundle
grep -n "skippable\|lsdirs" scripts/gates.mjsat basec02e88985· saw:skippableat:23, honoured bywalkDirs(:57),findFile(:75) andscanEnvReads(:1129);gateDataflow'slsdirs(:842) a rawreaddirSync+isDirectory· concluded: one population, two definitions — the completeness walker is the only reader that never filters.python3 -m compileall -q core/flows/src && node scripts/gates.mjs dataflowat base · saw:completeness: 'core/flows/src/__pycache__' exists on disk but is not registered in architecture.calm.json;mkdir core/flows/src/.venv core/flows/src/zz.egg-info→ three rows;git statusempty throughout · concluded: gitignored residue is read as modules. Checkedgate:db-schema(python3 scripts/schema_digest.py):astparse, no imports, no bytecode — the residue comes from the pytest gates (gate:pythonandgate:healthrunuv run pytestincore/flows, whosetests/conftest.pyputssrconsys.path).lsdirsfilters with!skippable(n)before theisDirectorytest;skippablealso recognises*.egg-info(.gitignore:6), sogate:readmeand every otherwalkDirs()user close the same hole at once. Two lines of logic; the comments state the population, not the history.98f798988(residue present) · saw:✓ gate:dataflow — 99 nodes · 68 edges · 11 carriers · complete + sealed,✓ gate:arch-report — every modularity principle maps to a green gate· ran:node --test --test-reporter=tap scripts/gates.test.mjsat head · saw: 25/25 (21 existing + 4 new) · ran: the 4 new rows against basescripts/gates.mjs· saw:not okon the__pycache__row and on the.venv/*.egg-inforow,okon the vacuity control and on the negative control · ran:git pushthrough.githooks/pre-push· saw: all 14 fast gates green,dataflowamong them, aftercontract-conformance's pytest had run in the same worktree.git cherry-pick 98f798988ontominutes-mcp-viewerad97be131:scripts/gates.mjsapplies cleanly; thescripts/gates.test.mjshunk meets the Release 0.10.0-260419-0052 #209gate:pythonsection that follows the same anchor there — a one-hunk placement at the next main→line merge. The line's run result follows as a comment.Acceptance floor
__pycache__,.venv,zz_probe.egg-infoundercore/flows/src) →gate:dataflow✓ andgate:arch-report✓ at head98f798988; same plant at basec02e88985→✗ completeness: 'core/flows/src/__pycache__' …plus one row each for.venvand the egg-infoscripts/gates.test.mjsokat head; the same rows against basegates.mjs:not ok 2,not ok 3(2 pass / 2 fail of the 4)negative control: a real package dir in the same place still reds, named by path—okat head; the message readscompleteness: 'core/flows/src/zz_planted_pkg' exists on disk but is not registerednode --test scripts/gates.test.mjs25/25 at head afterpnpm install --frozen-lockfile(a worktree withoutnode_modulesredsgate:schemaandconfig-contractonajv— the #1107 hint case, unrelated); the pre-push fast subset green;gatesCI on this PRDocs diff (D6c)
None.
docs/docs/governance/architecture.mdx:138states whatgate:dataflowenforces and that is unchanged; no page describes the walker's population;.gitignorealready names the residue. Tooling-only, so no changelog fragment (docs/changelog.d/README.md).Security checks
scripts/gates.mjsandscripts/gates.test.mjs; no dependency, lockfile or runtime change — dependency/licence scan not applicable;pnpm gate:licensesran green in the pre-push subset.git diff c02e88985..98f798988 -U0 | grep -Ei '(api[_-]?key|secret|token|password|BEGIN (RSA|OPENSSH)|AKIA)'→ no matches.node --checkclean on both files.core/flows/srcin the checkout and remove only what they created (thewithPlantedprune discipline); a pre-existing__pycache__is left as found.Validation request
Any non-author maintainer, on a worktree where
gate:pythonorpnpm gateshas run: A1 isnode scripts/gates.mjs dataflow && node scripts/gates.mjs arch-reportwithout deleting bytecode first. The operator who hit this during the v0.13.1-alpha.2 freeze is the preferred signer.D12b: no deployment applies — CI tooling only. Provenance of the measurements: fresh
git worktreeofVexa-ai/vexaat basec02e88985on macOS (Darwin 25.5), Node v24.13.0, Python 3.13.11, pnpm 11.7.0, no env deltas beyondONNXRUNTIME_NODE_INSTALL=skipfor the install; a second throwaway worktree at the same base for the red-at-base rows.Authorship
Submitted by the maintainer. Tooling disclosure: diagnosed, drafted and measured with an agent; no co-author trailers.