Deliver: Premise-Freshness Lint - #83
Merged
Merged
Conversation
Author: architect Waves: 2 Tasks: 3 Out-of-scope deps: no
Plan: .agents/plans/premise-freshness-lint.md (Status + approved event written by: node harness/cli.js approve)
…lpers + unit tests Wave 1, Tasks 1.1 + 1.2 Validated: AC#1, AC#4, AC#6 — bash scripts/test-plan-paths.sh (ALL PASS)
Wave 2, Task 2.1 Validated: AC#2, AC#4, AC#5, AC#6 — bash scripts/test-lint-plan.sh (ALL PASS)
…y-low-risk.sh Wave 2, Task 2.2 Validated: AC#3, AC#4, AC#5 — bash scripts/test-classify-low-risk.sh (ALL PASS)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #74.
Summary
Adds a premise-freshness check so a plan anchored to deleted/renamed code is caught before deliver time (the "develop-drift" failure class, upstreamed from BEAKON green-lane criterion 10). Cited
path:lineanchors, per-taskFile:paths, and Files-in-Scope entries must exist onorigin/<default_branch>— unless the plan itself creates them.scripts/lib/plan-paths.sh— three new shared helpers (one source of truth for both consumers):plan_cited_anchors(inline anchor extractor, real-path-shape filtered),plan_created_paths(CREATE-exempt set from the Files-in-Scope table),path_exists_on_ref(existence-only, fail-closed return codes: 0 present / 1 absent / 2 unresolvable ref). — 68152afscripts/lint-plan.sh— advisory freshness block (warns, never errors; exit 0 preserved). — b66675fscripts/classify-low-risk.sh— Rule 0.5 stale-premise eligibility (any absent non-exempt path ⇒ not-low; a stale-premise plan is never auto-clearable). — 64ac5faDesign decisions
git fetch— both checks query the locally-knownorigin/<default_branch>ref only, keepinglint-plan.shoffline-pure. An unresolvable ref fails closed (advisory in lint, not-low in classify).:NNNsuffix is stripped before the query.new file/ col-4^New), since there is no per-taskCreates:field.Test coverage
New co-located tests, all green (216/216 harness + all script suites):
scripts/test-plan-paths.sh(new) — unit tests for all three helpers incl. suffix-strip, non-anchor rejection, present/absent/unresolvable-ref return codes, created-path detection.scripts/test-lint-plan.sh— freshness advisory: existing path (no warn), absent path (warn + exit 0), created-file exempt, exit 0 throughout.scripts/test-classify-low-risk.sh— stale premise: all-present stays low, absent ⇒ not-low, created file stays eligible.Notes for review
🤖 Generated with Claude Code