Problem
From verification of #53 (PR #58):
「Leading whitespace narrowing — ## Diagnosis (CommonMark legitimate 1-3 space indent) 從 substring true → 新 anchored regex false。Canonical IDD diagnosis comments 為 col-0,實務上不會踩到;但若 user 手動 paste 帶 indent 會 false-negative」
— Source: team:devils-advocate (HIGH self-rated) + codex (ACCEPTED RISK)
新 regex test("(?m)^## Diagnosis") 在嚴格 line-start anchor 下,完全排除 CommonMark spec 允許的 1-3 space leading indent ATX heading。
Type
enhancement (regex precision)
Priority
P3 (canonical IDD never hits; risk only on user manual paste)
Trigger scenario
GitHub comment body contains:
## Diagnosis ← 3-space indent, CommonMark legitimate H2
...content...
Phase 0.4 detection:
- old contains("## Diagnosis") → true
- new test("(?m)^## Diagnosis") → false
- result: chain-shell falsely concludes "no diagnosis", prompts user re-run
Acceptance
Related
Source: surfaced during /idd-verify --pr 58 (cluster #49 #53), Step 5b triage. Master report: #58 (comment)
Problem
新 regex
test("(?m)^## Diagnosis")在嚴格 line-start anchor 下,完全排除 CommonMark spec 允許的 1-3 space leading indent ATX heading。Type
enhancement (regex precision)
Priority
P3 (canonical IDD never hits; risk only on user manual paste)
Trigger scenario
Acceptance
test("(?m)^[ \\t]{0,3}## Diagnosis"),smoke test 加 case 5 (## Diagnosis\n→ true)Related
Source: surfaced during /idd-verify --pr 58 (cluster #49 #53), Step 5b triage. Master report: #58 (comment)