Repository navigation
fix(pr-blog): the dispatch REPO constant follows the org rename (refs #1746) - #1754
Conversation
…d dying on 'Unexpected source repository' (refs #1746)
X Brain Health CheckScore: 100.0/100 X Brain is above merge threshold |
Summary by t27-beesThis PR updates hardcoded repository references from the old organization name Worth a look
Read: 5 files, +22 -22, the whole diff. Head |
🧪 Brain Stress Test ResultsTests: 261/261 passed, 0 leaked |
What broke
Every run of the "PR work report and blog" workflow dies at its last step:
Cause:
scripts/pr_blog_dispatch.pystill saidREPO = "gHashTag/trinity"-- the organization was renamed toTrinity-S-AI-DNAafter the script last changed (2026-10-02, #1261), sopr.base.repo.full_nameno longer matches. The check runs before the unmerged early-return (Draft saved; unmerged PR is not sent), so every PR's report job goes red -- #1751 and #1753 included.The fix -- the whole rename class, five files
pr_blog_dispatch.py: the constant follows the rename.pr_blog_author_guard.py: the same hardcoded repo in the author-side guard of the same pipeline.gHashTaguser-login fixtures are names, not repositories, and stay.Verified with the exact CI command --
python3 -m unittest discover -s scripts -p 'test_pr_blog*.py': 74 tests, OK (18 errors before the fixture and guard renames).Note: this PR's own
reportcheck stays red until this lands (the workflow runs the script frommain). That red is the bug itself.Left for its own regeneration:
scripts/ci-gate.generated.json(TRAINING_REPO, a different pipeline's generated artifact).Refs #1746. Unblocks the report chain for #1751 and #1753.
Foreign-code note
Five existing foreign files under
scripts/. Under the Only-t27 law this needs theowner-approved-foreignlabel, which this PR carries. Owner approval: given 2026-10-25 in the t27 session -- the instruction to run the night queue's fixes autonomously.{ "version": 1, "head_sha": "2938dd75ef0382b0d9f330cbe2f6b83e129416f4", "summary": "The PR blog pipeline still names the pre-rename organization in its dispatch and author-guard constants and in three test fixtures, so every work-report run dies at the dispatch step; the whole rename class is followed here.", "changes": [ "scripts/pr_blog_dispatch.py: REPO constant updated from gHashTag/trinity to Trinity-S-AI-DNA/trinity -- the stale line behind 'Unexpected source repository', hit by every PR including unmerged ones because the check precedes the Draft-saved early-return.", "scripts/pr_blog_author_guard.py: the same hardcoded repo value follows the rename -- the author-side guard of the same pipeline carried the identical bug.", "scripts/test_pr_blog_report.py, scripts/test_pr_blog_dispatch.py, scripts/test_pr_blog_author_guard.py: the sixteen gHashTag/trinity fixture values follow the rename; the bare gHashTag user-login fixtures are deliberately untouched." ], "tests": [ { "command": "python3 -m unittest discover -s scripts -p 'test_pr_blog*.py' (the exact CI command)", "result": "Ran 74 tests, OK -- the same discovery failed 18 errors before the fixture and author-guard renames", "status": "passed", "evidence": "Run locally on this branch head with apps/website/specs/policy/course_post.t27 present, 2026-10-25." }, { "command": "grep -rn 'gHashTag/trinity' scripts/pr_blog_dispatch.py scripts/pr_blog_author_guard.py scripts/test_pr_blog*.py", "result": "0 remaining repository-name references; the two bare gHashTag login fixtures in test_pr_blog_report.py are user names and stay", "status": "passed", "evidence": "Grep before and after the edits in the fix session on 2026-10-25." }, { "command": "gh run view --job 121204703214 (run 40205258022, PR #1753)", "result": "the failing step is the dispatch repo check, which runs before the unmerged early-return; the edit addresses exactly that comparison", "status": "passed", "evidence": "Read the job log via gh in the fix session on 2026-10-25." } ], "limitations": [ "This PR's own report job runs the pre-fix script from main (pull_request_target checks out the base), so it stays red until this lands -- that red check is the bug itself, not a regression.", "scripts/ci-gate.generated.json still carries TRAINING_REPO gHashTag/trinity-training; it is a generated artifact of a different pipeline and is left for its own regeneration." ], "tags": [ "Ci", "Blog", "Rename" ], "blog": { "title": "The blog pipeline died on the old organization name", "summary": "Two constants and sixteen test fixtures kept the pre-rename organization after the rename to Trinity-S-AI-DNA, killing every work-report run at the dispatch step; this PR follows the rename across the whole class.", "outline": [ "What broke and when: the dispatch script last changed on 2026-10-02, the organization was renamed afterwards, and every report run since then failed the source check.", "Why the whole class had to move together: renaming the constant alone failed eighteen fixture-driven tests, and the author guard of the same pipeline carried the identical bug.", "What is deliberately not here: the generated ci-gate artifact with the training-repo name stays for its own regeneration, and the bare user-login fixtures are names, not repositories." ] } }