refactor: doctor の Codex 権限面ウォッチを関数抽出 (PR-3/4, Refs #189) - #192
Merged
Conversation
…(Refs #189) ultracode 監査の CONFIRMED 所見 (structure)。出力・順序・exit 0 契約は 不変 (旧新 doctor の実出力 diff で確認・PR 本文)。 - AI policy 節の Codex ブロック (~120 行・5 段ネスト) を report_codex_rules_probes / report_codex_projects_trust の 2 関数へ 同一ファイル内抽出 (lib-policy.sh へは移さない: validate-policy.sh の capability-registry check が doctor.sh の source テキストを grep する ため)。module ゲートと inactive 側の item は call site に残す。使用 変数は関数 local 化 (repo 全体 grep で抽出範囲外の参照ゼロを確認済み) - enforceAiSandbox の capability_value を 1 回 capture して sandbox 節と injection-guard 節で再利用 (npm_mode と同型の single-read パターン。 yq 起動が 1 回減るだけで判定値は同一) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016qw8BkUDu5WdwhYfiFFX5n
Owner
Author
Codex 相互レビュー結果(author=Claude → reviewer=Codex)
判定: ✅ merge 可(must 0 件) — should 0 / nit 0 重点観点の検証結果(Codex 出力より):
author 側検証: 全 16 suite green / 旧新 doctor 実出力(personal+work・rc+stdout+stderr)が正規化後 byte-identical。 |
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.
Refs #189 の PR-3/4。ultracode 監査 CONFIRMED 所見(structure)。
変更内容(挙動不変)
report_codex_rules_probes/report_codex_projects_trust。この節は doctor で最も追記頻度が高く(ai-policy モジュールの実体化: AI エージェント権限方針の正本化(Codex 側との対称性) #139/Codex 側の PreToolUse hooks 登録(personal-safe-gh-hook の Codex 活性化・#137 の Codex parity) #181/settings.json.tmpl に PreToolUse hooks 登録を追加(personal-safe-gh-hook の活性化) #137)、毎回 5 段ネストの中を編集していた。module_active_for_profile)と inactive 側の item は call site に残すif trusted_paths=$(awk ...)の rc を if が見る現行セマンティクスは維持|| true不要)capability_value二重 yq 起動を 1 回 capture に(npm_mode と同型)挙動不変の検証(実施済み)
レビュー観点
🤖 Generated with Claude Code
https://claude.ai/code/session_016qw8BkUDu5WdwhYfiFFX5n