chore: sync align local command templates #7
Loading…
Reference in a new issue
No description provided.
Delete branch "chore/align-local-forge"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Regenerates the repository's managed files with Align 13.0.0 so declaration-check recovery instructions use the current local repair command. Includes the staged-snapshot cleanup update and review wrapper update with the existing zero-failure requirement retained.
Review
01M5PDGEDE5CD91721E8DVPCX3— head4cf847551453ad737a9b0761c1a4e57a2d14259cReview — j4k-oss/perplexity-agent-mcp @
eaf7864b77Scope: diff against base tree
5368bdadc54dReview finished: 10 succeeded, 0 failed
Triage: settled
Facts: current review-wide projection
Computed under:
Findings (1)
medium — The watcher treats fd-6 EOF as "the hook is gone", so it deletes the snapshot while an orphaned
git worktree add(started with6>&-) is still writing into it01M5PDN1QT42FP6V491HHZWKT8.githooks/commit-msg(snippet)01M5PDPZARC71HRAS7T36V2XEW· valid: The grounded anchor shows git worktree add launched with 6>&- and no process-group tracking. The reviewer quotes the comment above exec 6> that pushes onto every later command the duty to close fd 6 on any command that can leave a process behind. They also show that only run_step pairs that closure with tell_watcher. So the watcher's liveness rule (the hook counts as dead once every fd-6 holder exits) is hidden knowledge each call site must re-derive. Getting it wrong fails silently either way: the watcher hangs if a daemon keeps fd 6, or cleans up underneath an untracked orphan. This is the Information Leakage / Nonobvious Code red flag, plus the 'pull complexity downward' principle, with a concrete cost at the anchored line. The unix-cli claim's reproduction independently confirms the orphan survives the cleanup. The proposed remedies (a single spawn helper, or tracking the hook PID) fit the defect. One overstatement: the inference that Git recreates the directory and leaves a partly populated snapshot is unverified. The unix-cli reproduction instead shows the resumed checkout failing with 'unable to create file ... No such file or directory', so the leftover state is the surviving orphan process and possibly a stale worktree registration, not necessarily recreated files. Low to medium severity fits.01M5PDP5Q5SCB8TV0FWMH5B15E(unix-cli)Other claims
01M5PDP5Q5SCB8TV0FWMH5B15Emedium — The snapshot watcher leaves checkout processes running after the hook is killed →01M5PDN1QT42FP6V491HHZWKT801M5PDK6M07DZ8ZNK499SBDGEWmedium — The recursion guard duplicates the wrapper's write-operation inventoryCoverage
Coverage pass: 01M5PDGEPW8RY10AN9J5HDYVYJ
Accounting: complete (all slots terminal; see slot results for failures)
Slot health: healthy
@ -146,2 +205,3 @@exec 6> >(set -m; watch_snapshot <&0 > /dev/null &)# Relative worktree paths would upgrade the repository format; post-checkout hooks must not run here.git --git-dir="$git_common_dir" -c worktree.useRelativePaths=false -c core.hooksPath=/dev/null worktree add --quiet --detach "$snapshot_dir" "$snapshot_commit"git --git-dir="$git_common_dir" -c worktree.useRelativePaths=false -c core.hooksPath=/dev/null worktree add --quiet --detach "$snapshot_dir" "$snapshot_commit" 6>&-medium — The watcher treats fd-6 EOF as "the hook is gone", so it deletes the snapshot while an orphaned
git worktree add(started with6>&-) is still writing into itlens
aposd-plain· armdefault· tally 1 valid / 0 invalid / 0 uncertainclaim
01M5PDN1QT42FP6V491HHZWKT8of review01M5PDGEDE5CD91721E8DVPCX3Confirmed with real Git on macOS, without filters: killing only the hook during delayed snapshot checkout can leave a temporary snapshot and worktree registration. The current hook retains this documented limitation; this PR does not fix it. The producer correction and focused regression are owned by j4k/align#826, which routes checkout through the existing run_step helper. Consumers will receive the generated correction after that release.
For unadjudicated claim 01M5PDK6M07DZ8ZNK499SBDGEW, the recursion comment is a manually maintained copy, so its maintenance cost is real. Inspection of review-wrapper at the pinned 7725fcb7d0300c467c6b0224f7d442df98756481 found its mutation methods create/edit issue comments, create COMMENT reviews/add review comments, and resolve/unresolve conversations. Those operations fit the comment's categories; no current mismatch was found. We retain the three explanatory lines and decline the optional prose rewrite within this migration scope. This does not claim that duplication was disproved or that Forgejo event semantics were freshly tested.