Repository navigation
docs(knowledge): record zsh scope, Pages and sub-issue branch rules - #813
Merged
Merged
Conversation
Localizing path, PATH, cdpath, fpath or manpath empties the command hash table on return and forces a full PATH rescan; an EXIT trap set inside a function fires when that function returns. The zsh domain index names the policy validator tests, the CI index says static.yml publishes Pages (build_type workflow), and implementation branches are named after their repository sub-issue. The frozen consumer-parser digest is updated for the scripting instruction change (#588).
strace on zsh 5.9.2 shows a local path or PATH doubling the PATH directory scans (86 against 43 getdents64 calls), while a local fpath, cdpath or manpath does not rescan. The frozen consumer-parser digest follows the instruction change (#588).
ss-o
commented
Oct 19, 2026
ss-o
left a comment
Member
Author
There was a problem hiding this comment.
Fallback review under ADR-0026: Copilot request not registered on ee32b0c
Findings
No actionable findings.
Scope: the full diff of 2c37bfe...ee32b0c (7 files: the scripting standard source and its delivery, the zsh and CI domain indexes, the sub-issues source and its delivery, and the frozen digest in test_validate_zsh_standard_policy.py). Needs meta:no-issue from the maintainer under ADR-0022.
Note
The maintainer elected this fallback after the Copilot request did not register (no review_requested event). It is a self-review by the authoring agent, not an independent review or approval to merge.
Validation
- Passed: all PR checks on ee32b0c. Locally:
knowledge-delivery.py --check(57 consumers),knowledge-coverage.py(366 files),validate-zsh-standard-policy.py,test_validate_zsh_standard_policy(111 tests),test_validate_agent_policy.py(99 tests). - Claims checked at source: strace on zsh 5.9.2 counts 86
getdents64calls withlocal pathorlocal PATHagainst 43 withlocal fpath,cdpath,manpathordir; anEXITtrap set in a function fires on its return;gh api repos/z-shell/.github/pagesreportsbuild_type: workflowandstatic.ymldeploys withpages: write. - Pre-existing: Trunk prettier reports the compact tables in
knowledge/domains/*/index.mdas unformatted, including untouched index files.
Checklist verdicts and supporting evidence
- Documentation accuracy: pass after fixes. Self-review before posting corrected two of the author's claims: the rescan note first named
cdpath,fpathandmanpathtoo (5442fdc), and the validator time read "about two minutes" against 45 s measured (ee32b0c). - Generated ownership: pass. Edits are in the
knowledge/domainssources; the delivered copies were regenerated and--checkis clean. - Frozen digest: pass. Updated as the test's own message instructs for a scripting instruction change (#588).
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
Moves four verified rules that were only kept in agent memory into their knowledge owners. Closes #814.
knowledge/domains/zsh/scripting.md(delivered to.github/instructions/zsh/scripting.instructions.md):zsh/parameters/avoid-special-name-collisions: evenlocal pathwithout assignment empties the command hash table when the caller's value is restored, so the next lookup rescans everyPATHdirectory;local PATHdoes the same, whilefpath,cdpathandmanpathdo not rescan.zsh/cleanup/scope-traps: anEXITtrap set inside a function, anonymous ones included, runs when that function returns; whole-file cleanup traps go at the sourced file's top level.knowledge/domains/zsh/index.md: the policy validator test command and its fast class.knowledge/domains/ci/index.md: Pages usesbuild_type: workflow, so thesourcebranch in its settings is inert andstatic.ymlpublishes.knowledge/domains/governance/sub-issues.md(delivered torunbooks/sub-issues.md): file the repository sub-issue before naming the implementation branch, and name the branch after it, never after the organization parent.automation/ci/test_validate_zsh_standard_policy.py: the frozen consumer-parser digest is updated for the scripting instruction change, as the test instructs (chore(ci): explain how to regenerate the frozen consumer-parser golden #588).Verification
strace -f -e trace=getdents64 -coverf() { local path; }; : ${+commands[ls]}; f; : ${+commands[ls]}counts 86 calls, against 43 withlocal dir,local fpath,local cdpathorlocal manpath, and 86 withlocal PATH;f() { trap "print fired" EXIT; print in-f; }; f; print afterprintsin-f,fired,after.gh api repos/z-shell/.github/pages:build_typeisworkflow,source.branchismetrics;static.ymldeploys withpages: write.python3 automation/knowledge/knowledge-delivery.py --check: 57 consumers checked.python3 automation/knowledge/knowledge-coverage.py: 366 files checked.python3 automation/ci/validate-zsh-standard-policy.py: passed.cd automation/ci && python3 -m unittest test_validate_zsh_standard_policy: 111 tests OK.python3 -m unittest automation/agents/test_validate_agent_policy.py: 99 tests OK.knowledge/domains/*/index.mdas unformatted; untouched index files report the same, so this is not new.Agent handoff
No handoff needed.