fix(ci): guard check-agent-originality.sh's AGENT_DIRS in check-divisions.sh - #650
Closed
Synvoya wants to merge 1 commit into
Closed
fix(ci): guard check-agent-originality.sh's AGENT_DIRS in check-divisions.sh#650Synvoya wants to merge 1 commit into
Synvoya wants to merge 1 commit into
Conversation
…AGENT_DIRS The divisions consistency check validated the AGENT_DIRS bash arrays in convert.sh and lint-agents.sh, but not the Python AGENT_DIRS list in check-agent-originality.sh — so that list silently drifted out of sync (it was missing the gis and security divisions). Add a Python-list extractor and compare it against divisions.json too, closing the gap that allowed the drift.
Owner
|
Thanks for catching the drift here — you're right that Closing this as superseded by #659, which fixes the root cause: instead of patching the hardcoded list, #659 has the script read |
msitarzewski
added a commit
that referenced
this pull request
Jul 5, 2026
check-agent-originality.sh hardcoded its own copy of the division list (AGENT_DIRS) in the Python heredoc — a 5th copy that check-divisions.sh's bash-array parser never saw, so it drifted: it was missing `gis` and `security` and still carried the retired `strategy`. The practical effect was that every gis/ and security/ agent — including newly added ones — skipped the duplicate-detection scan entirely. Read divisions.json directly instead of hardcoding, so this check can never drift from the catalog again. Now scans all 16 divisions; verified green in full-audit mode. Supersedes #649/#650, which patch the hardcoded constants rather than removing them. Claude-Session: https://claude.ai/code/session_01WKnDRWM4izsB8WAXKszhsq Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
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.
What does this PR do?
Root-cause follow-up to #649.
scripts/check-divisions.shenforces that theAGENT_DIRSarrays inconvert.shandlint-agents.shmatchdivisions.json— but it does not check the (Python)AGENT_DIRSlist incheck-agent-originality.sh. That gap is exactly why that list was able to silently drift (see #649). This adds a Python-list extractor and compares it againstdivisions.jsontoo, so the originality script's division set can no longer drift unnoticed.This new guard catches the drift that #649 fixes, so on the current
maincheck-divisions.shwill (correctly) fail here, reportingmissing: gis security/extra: strategyagainst the not-yet-fixed originality list. Merge #649 first; then this is green. (Verified: with #649 applied,check-divisions.sh→PASSED: 16 divisions consistent.)Testing
scripts/check-divisions.sh→ PASSED (16 divisions consistent across divisions.json, dirs, and all three scripts).gis/security+ extrastrategy.bash -n scripts/check-divisions.shclean.Notes
CI/tooling change — happy to fold this into #649 or move to a Discussion first if you'd prefer, per CONTRIBUTING. Kept separate so the fix and the guard-against-recurrence are reviewable independently.