Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion .claude/skills/issue-contract-review/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,8 @@ BLOCKED 時は issue comment に以下を記載:

**前提**: AC は「実装前 baseline で fail し、実装後に pass する」検証スクリプトとして書かれている。

**VC canonical format**: `## Verification Commands` セクション内の fenced bash block(` ```bash ... ``` `)が canonical VC format である。各コマンドは `$ <command>` 形式で記載し、コマンド直前行に `# ACN` マーカーを付ける。fenced bash block 以外の形式(インライン code span、プレーンテキスト等)は VC として認識されない。

**実行方法**

```bash
Expand All @@ -143,6 +145,9 @@ script は各 VC 実行結果を以下の category で分類(classify_result

| category | 条件 | decision | 説明 |
|---|---|---|---|
| `unsupported_shell_syntax` | `$(...)` / backtick / `${...}` を含む、または shlex parse 失敗 | blocked | 実行前静的遮断。run_command() を呼ばない |
| `unsafe_command` | `bash`, `sh`, `python -c`, `python3 -c`, `curl`, `wget`, `rm`, `mv`, `git push`, `git commit` 等の危険コマンド | blocked | 実行前静的遮断。run_command() を呼ばない |
| `command_not_allowed` | allowlist 外のコマンド(default blocked)、`gh api`, `pnpm add`, `npm install` 等 | blocked | 実行前静的遮断。run_command() を呼ばない |
| `file_not_found_expected` | `test -f` / `test -d` + exit 1 | go | 期待通り baseline fail |
| `file_not_found_unrunnable` | `No such file or directory` stderr + 実行対象 missing | blocked | 想定外の missing |
| `env_missing_dep` | stderr に `No module named` / `ModuleNotFoundError` / `command not found` / `Permission denied` 等 or exit 126/127 | blocked | 環境不備 |
Expand All @@ -152,7 +157,13 @@ script は各 VC 実行結果を以下の category で分類(classify_result
| `unexpected_pass` | exit_code = 0 | blocked | VC が緩すぎるか既に機能存在 |
| `unknown` | 上記いずれにも該当しない | human_judgment | 分類不能 |

分類ロジック(classify_result 関数):
分類ロジック(classify_static_command + classify_result 関数):
0. 静的遮断(classify_static_command、run_command より前):
a. `$(...)` / backtick / `${...}` → `unsupported_shell_syntax` / blocked
b. shlex parse 失敗 → `unsupported_shell_syntax` / blocked
c. denied command(bash, sh, curl 等) → `unsafe_command` / blocked
d. git/gh/pnpm mutation subcommand → `unsafe_command` / `command_not_allowed` / blocked
e. allowlist 外コマンド → `command_not_allowed` / blocked
1. compound command 検出 → `compound_command_disallowed` / blocked
2. timeout 検出 → `timeout` / blocked
3. exit_code = 0 → `unexpected_pass` / blocked
Expand Down
Loading
Loading