From fead39f00dc20be76189e59477a2b958ff9cf0ef Mon Sep 17 00:00:00 2001 From: Neil <4138956+nwparker@users.noreply.github.com> Date: Sun, 12 Apr 2026 23:23:08 -0700 Subject: [PATCH] Refactor code comments section in AGENTS.md Removed bullet points from the code comments section and streamlined the text. --- AGENTS.md | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 7f9a1586c84..0873e02859e 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -2,15 +2,7 @@ ## Code Comments: Document the "Why" -When writing or modifying code driven by a design doc or non-obvious constraint, you **must** add a comment explaining **why** the code behaves the way it does. "What" is visible in the code; "why" is not. Target these categories: - -- Safety constraints (suppressed actions, guarded entry points) -- Fallback/error-handling choices and their rationale -- Architectural boundaries (IPC separation, which surface owns a feature) -- Compatibility shims (fields that exist for downstream plumbing, not semantics) -- Intentional omissions (skipped data, unsupported edge cases) - -If the design doc has a gotcha, the code must have a comment. A maintainer who hasn't read the doc should still understand why the code must not be changed casually. +When writing or modifying code driven by a design doc or non-obvious constraint, you **must** add a comment explaining **why** the code behaves the way it does. ## Worktree Safety