fix(brain-allowlist): include root-level design + test-plan docs in artifacts sync#1489
Closed
genisis0x wants to merge 1 commit into
Closed
Conversation
…rtifacts sync
Several skills write their output at the project root, not under the
designs/ or ceo-plans/ subdirectories that the existing allowlist
covers:
- /office-hours Builder/Startup writes
projects/{slug}/{user}-{branch}-design-{datetime}.md
- /plan-eng-review writes
projects/{slug}/{user}-{branch}-eng-review-test-plan-{datetime}.md
- /autoplan test-plan writes
projects/{slug}/{user}-{branch}-test-plan-{datetime}.md
Cross-skill readers (plan-ceo-review, plan-eng-review, autoplan) glob
these at the project root via projects/$SLUG/*-design-*.md, so the
write paths are authoritative; the allowlist is the inconsistent piece.
Effect: with artifacts_sync_mode=full, gstack-brain-sync silently skips
all three doc types. CEO plans sync but the designs they reference do
not, breaking the cross-machine ceo-plan -> design chain.
Add three root-anchored glob patterns to both the allowlist and the
privacy-map (class: artifact, mirroring designs/). Glob '*' does not
match path separators, so the new patterns do not conflict with the
existing designs/*.md or ceo-plans/*.md entries.
Refs garrytan#1452
Contributor
Author
|
Closing as a duplicate of #1465. #1465 (rebased onto latest main today) adds the same If #1465 needs scope tightening rather than landing as-is, happy to re-open this one as a narrower fallback. Otherwise the eng-review pattern arrives through #1465. |
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.
Summary
Fixes #1452:
gstack-artifacts-initwrites a.brain-allowlistthat coversprojects/*/designs/*.mdandprojects/*/ceo-plans/*.md, but several skills land their output at the project root, not in those subdirectories:/office-hoursBuilder/Startupprojects/{slug}/{user}-{branch}-design-{datetime}.mdoffice-hours/SKILL.md.tmpl:519/plan-eng-reviewprojects/{slug}/{user}-{branch}-eng-review-test-plan-{datetime}.mdplan-eng-review/SKILL.md.tmpl:85-86/autoplan(test plan)projects/{slug}/{user}-{branch}-test-plan-{datetime}.mdautoplan/SKILL.md.tmpl:525Cross-skill readers (
plan-ceo-review,plan-eng-review,autoplan) glob these at the project root viaprojects/$SLUG/*-design-*.md, so the write paths are authoritative; the allowlist is the inconsistent piece. Withartifacts_sync_mode=full,gstack-brain-syncsilently skips all three doc types, breaking the cross-machine ceo-plan -> design chain.Change
Add three root-anchored glob patterns to both:
.brain-allowlist(sogstack-brain-syncincludes them):.brain-privacy-map.json(same patterns,class: "artifact", mirroring the existingdesigns/entries).Glob
*does not match path separators, so the new patterns do not conflict with the existingprojects/*/designs/*.mdorprojects/*/ceo-plans/*.mdentries.Per the issue author's recommendation, the alternative (canonicalizing skill write paths under
designs/) would break the existing cross-skill readers. The allowlist fix is the lower-risk path.Files
bin/gstack-artifacts-init— allowlist + privacy-map block, 6 added lines, no removals.Test plan
bash -n bin/gstack-artifacts-init(verified locally — syntax OK).brain-privacy-map.json(verified locally — valid JSON)bun test test/brain-sync.test.ts— existing tests verify file existence only, not pattern contents, so the diff is non-breaking/office-hours, thengstack-brain-sync --once, confirm the root-level*-design-*.mdis enqueued and pusheddesigns/*.mdandceo-plans/*.mdpaths continue to sync as before