Conversation
|
No findings. The PR description includes sufficient testing for this runtime behavior change, including a representative real-CLI end-to-end dry-run verification. I did not run or build the PR, per instructions. |
58d5a88 to
f2351bf
Compare
|
No findings. The PR description documents sufficient testing for this runtime behavior change, including a representative built-CLI end-to-end dry-run verification. I did not run, build, or install anything from the PR, as instructed. |
1 similar comment
|
No findings. The PR description documents sufficient testing for this runtime behavior change, including a representative built-CLI end-to-end dry-run verification. I did not run, build, or install anything from the PR, as instructed. |
|
This branch has merge conflicts with |
|
Heads-up from #900: #969 adds a
|
f2351bf to
0d539c8
Compare
|
No findings. The PR description documents sufficient testing for this runtime behavior change, including a representative built-CLI end-to-end dry-run verification. I did not run, build, or install anything from the PR, as instructed. |
Summary
teamai hooks inject --dry-runpreviously performed a real injection. Forward the preview flag through config loading and shared reconciliation, and report a preview rather than installation.The patch is rebased onto main 6c5949f, including #958. A preview skips the new Codex trust pass in
finally, so it cannot change hook trust or persist the trust fingerprint. Real injection still trusts written hooks, including when reconciliation reports failure or throws after writing hooks. Silent output and error propagation are preserved.The bilingual usage guides and changelog describe the preview. Skill usage text is left unchanged, following the updated AGENTS.md guidance.
Type of Change
Test Plan
Local Windows, Node 24.19.0:
npx tsc --noEmit), lint, build, andgit diff --checkpass.npx vitest run src/__tests__/hooks-cmd.test.ts -t hooksInject: 18 passed. Covers preview/silent/error paths plus the existing normal and failure-path Codex trust cases. Four preview cases fail if the new finally trust call is left unconditional.npx vitest run --config vitest.e2e.config.ts src/__tests__/e2e/hooks-inject-dry-run.test.ts: 1 passed against the built CLI. With isolated HOME and a fake Codex JSON-RPC app-server, a fresh preview preserves settings/config/manifest state; normal injection writes the fixture hook and actually performs a trust batch-write; a second preview preserves the installed files, trust fingerprint, and fake app-server state/call history.Related Issues and Coordination
Refs #900 (hooks inject).
#969 is still open at this update. Its guard currently refuses
hooks inject. If #969 lands first, this PR must movehooks injectfromNO_DRY_RUN_PREVIEWintoDRY_RUN_PREVIEW; if this PR lands first, #969 needs that classification change. The current main has no guard file, so this patch does not copy another open PR's implementation.Shared-State Review
Config migrations are previewed by
autoDetectInit. Reconciliation resolves and reports hooks without writing tool settings, managed manifests, or Git hooks under dry-run. The Codex trust pass is the additional writer introduced by #958: it can change Codex trust and savecodexTrustFingerprint, so this command skips that pass only for previews. Normal injection and its trust failure handling remain on the upstream path.Cross-PR integration check (2026-10-04)
In a separate unpublished worktree, combined #969 at 07e512f with this PR and the other preview fix (#949/#951). With the guard's original refusal classifications, all three built-CLI preview cases fail with exit 1. Moving hooks inject and update into DRY_RUN_PREVIEW and removing their NO_DRY_RUN_PREVIEW entries makes both classification tests and all three CLI E2E cases pass. This verifies the required merge-order adjustment; the classification patch belongs to whichever change lands second.