Skip to content

T-YBKU-shim-deletion-guard

Status: closed/done · Impact: high · Complexity: medium

The irreversible step: delete plugin/scripts/ and plugin/validators/ wholesale, and land the guard that keeps dead paths from coming back. Resolved design question (e) means no retained adapters — both directories go completely.

LocationRole today
plugin/scripts/T-0010 forwarding shims (new_*, audit_entities, migrate_entities, sdlc_lease), thinned port forwarders, and one-time tools (migrate_identifier_shape, check_dependencies.sh, _example_script, _pyyaml)
plugin/validators/validate_frontmatter (contract absorbed by T-Y1L0-entities-validate-absorb), validate_base, validate_sdlc_yaml (core absorbed by T-KO35-config-sdlc-yaml)
.claude/skills/project-check/home for the new guard script

Both directories deleted. A check_no_legacy_script_paths.ts project-check greps every plugin/skills/**/SKILL.md (all of them, not just invariant-instrumented skills) for ${CLAUDE_PLUGIN_ROOT}scripts/ and validators/ references — proven red on a planted fixture; per-skill forbidden_phrases invariants give local error messages; the guard is wired into lefthook/quality checks.

  1. Pre-delete gate: grep proves ZERO SKILL.md references to scripts/new_*, scripts/audit_entities, scripts/migrate_entities, validators/* — anything still referencing blocks deletion.
  2. git rm -r plugin/scripts plugin/validators; move any still-referenced test fixture out first.
  3. Land check_no_legacy_script_paths.ts + fixture test (red on planted violation, green on tree); wire into lefthook + quality checks.
  4. Add forbidden_phrases entries to instrumented skills’ invariants.yaml.
  5. Full bun test + every eval suite + fresh-project smoke.
LocationKindChange
plugin/scripts/deleteentire directory
plugin/validators/deleteentire directory
.claude/skills/project-check/check_no_legacy_script_paths.tsnewthe guard + fixture test
lefthook.ymlmodifywire the guard
plugin/skills/*/invariants.yamlmodifyforbidden_phrases entries
  • AC-1: plugin/scripts/ and plugin/validators/ do not exist; git log --follow still resolves history for every file that moved to lib.
  • AC-2: the guard exits 1 on a planted fixture violation and 0 on the clean tree; it runs in pre-commit.
  • AC-3: full bun test, every run_evals* suite, and the fresh-project smoke (sdlc project setuptask createentities auditindex generate) green on main.
  • AC-4: grep -rE 'plugin/(scripts|validators)/' plugin/ site/ returns only historical docs (task post-mortems), nothing live.
  • T-QL5F-skill-prose-codemod — every caller must be flipped first; this PR merges only when main is green with all prior PRs in.
  • D-0007 §Migration steps 5–6 (forbid old paths post-cutover, delete shims); the all-SKILL.md guard scope comes from the refutation finding that the prose linter only checks invariant-instrumented skills.

T-QL5F-skill-prose-codemod


← Back to Tasks