refactor(config): T-1281 — the check domain retires its five scripts
All five gates are ported, tested against their failure paths, and the originals are gone. reach check is the only way to run them. Parity first, then deletion. Every case in test_check.py began as a parity case running the new implementation beside the script it replaced; that evidence is in the ticket. With the scripts retired there is nothing left to compare against, so the assertions become the spec and the file drops its "_parity" name. A parity test is scaffolding with a defined lifetime — keeping one after its subject is deleted would mean keeping the subject alive to be compared with, which is the opposite of a migration. Two gates could not be parity-tested in a fixture at all, and both reasons are findings rather than obstacles. canvas-version: canvas_sources globs from a __file__ root while the service resolves git through config.repo_root(), so a fixture would diff one tree and glob another — real history is used instead, including two genuine instances of the regression the gate exists to catch. systems-db-stamp: generator_sources raises at IMPORT time when the economy-db tree is absent, so the old script died before reaching any logic in every fixture. The ported service imports it lazily and after the absent/unstamped checks, which is exactly why those states are testable now and were not before. Hooks rewired: pre-commit runs reach check fact-ids, pre-push runs the other four. Both pass --no-input, because a hook has no TTY and a prompt there does not wait, it crashes. Both guard on `command -v reach` and skip with a message rather than blocking every commit on a missing tool. Make targets are RETIRED, not wrapped, per the D-263 split — with the mapping left as a comment where they used to be. Wrapping would leave two ways to invoke each gate, and reach --help would stop being the answer to "what tooling exists" while the Makefile remained a competing index. pre-pr-validate and pre-pr-content keep their orchestration role and lose the individual target. Sprint archives and workshop notes still name the old paths and are left alone: they record what was true when written. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -3,8 +3,8 @@ GODOT := $(shell command -v godot4 2>/dev/null || command -v godot 2>/dev/null)
|
||||
.PHONY: help setup build client server game atlas stop test test-tooling lint lint-python setup-venv ci ci-client ci-server clean \
|
||||
install-reach reach-repoint \
|
||||
decisions-sync decisions-active decisions-validate \
|
||||
validate-content check-fact-ids setup-hooks install-hooks \
|
||||
audit deny atlas-verify economy-db regen-db check-systems-db check-client-version check-canvas-version \
|
||||
validate-content setup-hooks install-hooks \
|
||||
audit deny atlas-verify economy-db regen-db \
|
||||
pre-pr pre-pr-lint pre-pr-build pre-pr-test pre-pr-validate pre-pr-fixtures \
|
||||
pre-pr-server pre-pr-client pre-pr-content \
|
||||
fixtures-client fixtures-gauntlet golden-diff golden-update \
|
||||
@@ -13,7 +13,7 @@ GODOT := $(shell command -v godot4 2>/dev/null || command -v godot 2>/dev/null)
|
||||
perf-baseline debug-schedule \
|
||||
test-ipc-fixtures test-ipc-protocol test-ipc-integration test-ipc-benchmark \
|
||||
screenshot visual-movie test-visual visual-update \
|
||||
manifest diagrams check-diagrams check-dataflow-graph
|
||||
manifest diagrams check-diagrams
|
||||
|
||||
# --- Configuration ---
|
||||
|
||||
@@ -56,15 +56,11 @@ help:
|
||||
@echo " make audit Run cargo audit (security advisory check)"
|
||||
@echo " make deny Run cargo deny check (license/ban policy)"
|
||||
@echo " make validate-content Validate content YAML against schemas"
|
||||
@echo " make check-fact-ids Check fact_id references against knowledge catalogs"
|
||||
@echo " make atlas-verify Verify atlas proposal JSONs (all in docs/atlas/proposals/)"
|
||||
@echo " make star-map-data Regenerate client/data/star_map_data.json from systems.db + wiki"
|
||||
@echo " make check-star-map Assert star_map_data.json is up to date (part of pre-pr-client)"
|
||||
@echo " make economy-db Import economics data into systems.db (TOML/JSON → SQLite)"
|
||||
@echo " make regen-db Regenerate systems.db from all sources + stamp meta table (#855)"
|
||||
@echo " make check-systems-db Verify systems.db meta stamp matches current generator sources"
|
||||
@echo " make check-client-version Verify client/project.godot version mirrors project.yaml"
|
||||
@echo " make check-canvas-version Verify canvas-generation changes carry a version bump"
|
||||
@echo " make install-hooks Install pre-push + pre-commit git hooks (once per clone)"
|
||||
@echo " make fixtures-client Generate GDScript->Rust cross-encoder fixtures (#475)"
|
||||
@echo " make golden-diff Show diff if golden file output has changed"
|
||||
@@ -319,10 +315,10 @@ test-tooling:
|
||||
@mkdir -p .cache
|
||||
@$(VENV_PY) tooling/test_conformance.py 2> .cache/test-tooling-conformance.log || \
|
||||
{ echo " FAIL: reach conformance — log follows:"; cat .cache/test-tooling-conformance.log; exit 1; }
|
||||
@echo " [test-tooling] reach/check-client-version parity (T-1262)..."
|
||||
@echo " [test-tooling] reach check gates — behaviour (T-1281)..."
|
||||
@mkdir -p .cache
|
||||
@$(VENV_PY) tooling/test_check_parity.py 2> .cache/test-tooling-check-parity.log || \
|
||||
{ echo " FAIL: check parity — log follows:"; cat .cache/test-tooling-check-parity.log; exit 1; }
|
||||
@$(VENV_PY) tooling/test_check.py 2> .cache/test-tooling-check.log || \
|
||||
{ echo " FAIL: check gates — log follows:"; cat .cache/test-tooling-check.log; exit 1; }
|
||||
@echo " [test-tooling] economy_import.traits validation units (T-995/PR #173 H2)..."
|
||||
@mkdir -p .cache
|
||||
@python3 tooling/economy-db/test_traits.py 2> .cache/test-tooling-traits.log || \
|
||||
@@ -382,7 +378,7 @@ pre-pr-build: build-server build-client
|
||||
pre-pr-test: test-server test-client
|
||||
@echo "--- Tests: PASS ---"
|
||||
|
||||
pre-pr-validate: validate-content check-fact-ids check-star-map
|
||||
pre-pr-validate: validate-content check-star-map
|
||||
@echo "--- Content validation: PASS ---"
|
||||
|
||||
pre-pr-fixtures:
|
||||
@@ -427,7 +423,7 @@ pre-pr-server: lint-server build-server test-server pre-pr-fixtures audit deny
|
||||
pre-pr-client: lint-client build-client test-client check-star-map
|
||||
@echo "=== Client pre-PR: PASSED ==="
|
||||
|
||||
pre-pr-content: validate-content check-fact-ids checklist-validate atlas-verify
|
||||
pre-pr-content: validate-content checklist-validate atlas-verify
|
||||
@echo "=== Content pre-PR: PASSED ==="
|
||||
|
||||
# --- CI (run locally) ---
|
||||
@@ -464,14 +460,19 @@ regen-db: ## Regenerate systems.db from all sources and stamp meta table (#855,
|
||||
echo " regen-db complete — systems.db is up to date and stamped."; \
|
||||
echo " Stage it with: git add server/data/systems.db"
|
||||
|
||||
check-systems-db: ## Verify systems.db meta stamp matches current generator sources (#857)
|
||||
@python3 tooling/check-systems-db-stamp --verbose
|
||||
|
||||
check-client-version: ## Verify client/project.godot's baked version matches project.yaml (T-1241)
|
||||
@python3 tooling/check-client-version
|
||||
|
||||
check-canvas-version: ## Verify canvas-generation changes carry a project.yaml version bump (T-1242)
|
||||
@python3 tooling/check-canvas-version
|
||||
# The five gate targets that lived here are RETIRED, not wrapped (D-263,
|
||||
# T-1281). They are tooling, and tooling has one door:
|
||||
#
|
||||
# make check-systems-db -> reach check systems-db-stamp
|
||||
# make check-client-version -> reach check client-version
|
||||
# make check-canvas-version -> reach check canvas-version
|
||||
# make check-fact-ids -> reach check fact-ids
|
||||
# make check-dataflow-graph -> reach check dataflow-graph
|
||||
#
|
||||
# Wrapping them would leave two ways to invoke each, and `reach --help` would
|
||||
# stop being the answer to "what tooling exists" because the Makefile would
|
||||
# still be a competing index. make keeps build and test ORCHESTRATION; it does
|
||||
# not keep aliases for individual tools.
|
||||
|
||||
econ-sim: ## Build the economics simulation binary (Layer 1+2: Leontief + tâtonnement trade)
|
||||
@cargo build --manifest-path tooling/econ-sim/Cargo.toml --release
|
||||
@@ -503,9 +504,6 @@ decisions-validate:
|
||||
validate-content:
|
||||
@tooling/validate-content
|
||||
|
||||
check-fact-ids:
|
||||
@tooling/check-fact-ids
|
||||
|
||||
atlas-verify:
|
||||
@tooling/atlas-verify docs/atlas/proposals/*.json
|
||||
|
||||
@@ -616,11 +614,6 @@ check-diagrams:
|
||||
test $$fail -eq 0 || { echo "Run 'make diagrams'."; exit 1; }; \
|
||||
echo "All diagrams rendered."
|
||||
|
||||
# D-262: every repo path named in a hand-authored data-flow diagram must still
|
||||
# resolve. Catches the stale half of a diagram; edge MEANING is a human check.
|
||||
check-dataflow-graph:
|
||||
@python3 tooling/check-dataflow-graph.py
|
||||
|
||||
# --- Clean ---
|
||||
|
||||
clean:
|
||||
|
||||
Reference in New Issue
Block a user