Skip to content

More AGENTS.md instructions#134

Merged
ejfine merged 8 commits intomainfrom
more-agents
Mar 13, 2026
Merged

More AGENTS.md instructions#134
ejfine merged 8 commits intomainfrom
more-agents

Conversation

@ejfine
Copy link
Contributor

@ejfine ejfine commented Mar 13, 2026

Why is this change necessary?

Better instructions to agents after empirically observing them not doing these things by default

How does this change address the issue?

Adds to AGENTS.md

What side effects does this change have?

N/A

How is this change tested?

Downstream repos

Other

Bumped some misc versions

Summary by CodeRabbit

  • Chores

    • Updated devcontainer tooling and extensions (Claude Code) and bumped several developer tool versions (UV, pnpm, ty, Pulumi and related packages) for consistency and stability.
  • Documentation

    • Added developer guidance on linting-disable comments, clearer test assertions, fixture usage, using name for refs, and choosing stable test selectors.

@ejfine ejfine self-assigned this Mar 13, 2026
@coderabbitai
Copy link

coderabbitai bot commented Mar 13, 2026

📝 Walkthrough

Walkthrough

Bumps devcontainer and tooling version pins (Claude Code extension, UV, pnpm, ty, Pulumi packages), removes a trailing comma in a devcontainer template, and adds linting/testing guidance to AGENTS.md.

Changes

Cohort / File(s) Summary
Devcontainer configuration
.devcontainer/devcontainer.json, template/.devcontainer/devcontainer.json.jinja-base
Updated Claude Code extension from 2.1.612.1.74; updated devcontainer context hash comment; removed trailing comma in aws-cli feature entry.
CI tooling installer
.devcontainer/install-ci-tooling.py
Bumped UV_VERSION from 0.10.80.10.9 (installer URL/version change only).
Context pins / extensions
extensions/context.py
Updated pinned versions in ContextUpdater.hook: uv 0.10.8→0.10.9, pnpm 10.30.3→10.32.1, ty >=0.0.19→>=0.0.23, Pulumi core ≥3.223.0→≥3.226.0 and related Pulumi packages bumped.
Project metadata
pyproject.toml
Bumped ty dependency from >=0.0.19>=0.0.23.
Guidance / documentation
AGENTS.md
Added rules for inline lint-disable comments, testing patterns (avoid loops, assert per item), stable data-testid usage, and fixture/patch guidance using __name__.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 1 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Title check ❓ Inconclusive The title 'More AGENTS.md instructions' is vague and does not clearly specify what instructions were added or the intent of the changes; it lacks specificity about the core improvements being made. Revise the title to be more specific about the key guidance added, such as 'Add linting, testing, and data-testid guidance to AGENTS.md' to better convey the changeset's primary improvements.
✅ Passed checks (1 passed)
Check name Status Explanation
Description check ✅ Passed The description covers most required sections from the template but lacks specific details and oversimplifies the scope of changes; version bumps are mentioned vaguely without clear justification.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@AGENTS.md`:
- Around line 10-11: The Markdown headings in AGENTS.md (notably the "Testing"
heading and the two subsequent headings referenced in the review) are missing a
blank line after each, triggering MD022 warnings; edit AGENTS.md to insert a
single blank line directly after each of those heading lines so every heading is
followed by an empty line, then re-run markdownlint to confirm MD022 is
resolved.
- Around line 28-30: The guidance is contradictory: the example "cd frontend &&
pnpm test-unit" uses chaining while the rule below forbids chaining; update the
✅ example to a non-chained form (e.g., run two separate commands or show just
the single-tool invocation like "cd frontend" then "pnpm test-unit" in separate
lines or separate bullets) and rewrite the sentence "and causing unnecessary
permission prompts" to "and cause unnecessary permission prompts"; ensure the
rule explicitly states that the example must not use &&, ||, ;, or & unless
explicitly requested and keep the prohibition on backslash continuations.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 8338ccf0-6aca-43e1-8819-fe9d68ef1b11

📥 Commits

Reviewing files that changed from the base of the PR and between 7a235db and 25de54c.

📒 Files selected for processing (5)
  • .devcontainer/devcontainer.json
  • .devcontainer/install-ci-tooling.py
  • AGENTS.md
  • extensions/context.py
  • template/.devcontainer/devcontainer.json.jinja-base

Comment on lines 10 to 11
## Testing
- Always run tests with an explicit path (e.g. uv run pytest tests/unit) — test runners discover all types by default.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Fix markdown heading spacing to satisfy MD022 warnings.

The headings at Line 10, Line 18, and Line 25 need a blank line after each heading.

Proposed markdownlint-compliant spacing
 ## Testing
+
 - Always run tests with an explicit path (e.g. uv run pytest tests/unit) — test runners discover all types by default.
@@
 ### Python Testing
+
 - When using `mocker.spy` on a class-level method (including inherited ones), the spy records the unbound call, so assertions need `ANY` as the first argument to match self:  `spy.assert_called_once_with(ANY, expected_arg)`
@@
 ## Tooling
+
 - Always use `uv run python` instead of `python3` or `python` when running Python commands.

Also applies to: 18-19, 25-26

🧰 Tools
🪛 markdownlint-cli2 (0.21.0)

[warning] 10-10: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@AGENTS.md` around lines 10 - 11, The Markdown headings in AGENTS.md (notably
the "Testing" heading and the two subsequent headings referenced in the review)
are missing a blank line after each, triggering MD022 warnings; edit AGENTS.md
to insert a single blank line directly after each of those heading lines so
every heading is followed by an empty line, then re-run markdownlint to confirm
MD022 is resolved.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

♻️ Duplicate comments (2)
AGENTS.md (2)

29-29: ⚠️ Potential issue | 🟡 Minor

Fix grammar in chaining rule sentence.

At Line 29, “and causing unnecessary permission prompts” should be “and cause unnecessary permission prompts.”

✏️ Proposed wording fix
-- When running terminal commands, execute exactly one command per tool call. Do not chain commands with &&, ||, ;, or & unless the user explicitly asks for it. Pipes (|) are allowed for output transformation (e.g., head, tail, grep). If two sequential commands are needed, run them in separate tool calls. Chained commands break the permission allow-list matcher and causing unnecessary permission prompts
+- When running terminal commands, execute exactly one command per tool call. Do not chain commands with &&, ||, ;, or & unless the user explicitly asks for it. Pipes (|) are allowed for output transformation (e.g., head, tail, grep). If two sequential commands are needed, run them in separate tool calls. Chained commands break the permission allow-list matcher and cause unnecessary permission prompts.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@AGENTS.md` at line 29, Update the chaining rule sentence to correct grammar:
replace "and causing unnecessary permission prompts" with "and cause unnecessary
permission prompts" in the sentence that begins "When running terminal commands,
execute exactly one command per tool call..." so the clause reads "...Do not
chain commands with &&, ||, ;, or & unless the user explicitly asks for it.
Pipes (|) are allowed for output transformation (e.g., head, tail, grep). If two
sequential commands are needed, run them in separate tool calls. Chained
commands break the permission allow-list matcher and cause unnecessary
permission prompts."

10-10: ⚠️ Potential issue | 🟡 Minor

Add blank lines below headings to satisfy MD022.

Line 10, Line 18, and Line 25 should each be followed by a blank line.

🧹 Proposed markdownlint-compliant spacing
 ## Testing
+
 - Always run tests with an explicit path (e.g. uv run pytest tests/unit) — test runners discover all types by default.
@@
 ### Python Testing
+
 - When using `mocker.spy` on a class-level method (including inherited ones), the spy records the unbound call, so assertions need `ANY` as the first argument to match self:  `spy.assert_called_once_with(ANY, expected_arg)`
@@
 ## Tooling
+
 - Always use `uv run python` instead of `python3` or `python` when running Python commands.

Also applies to: 18-18, 25-25

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@AGENTS.md` at line 10, Add a blank line immediately after each Markdown
heading to satisfy MD022: update AGENTS.md so every heading (e.g., the "##
Testing" heading and the other level-2 headings in the file) is followed by a
single empty line before the next paragraph or content.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In `@AGENTS.md`:
- Line 29: Update the chaining rule sentence to correct grammar: replace "and
causing unnecessary permission prompts" with "and cause unnecessary permission
prompts" in the sentence that begins "When running terminal commands, execute
exactly one command per tool call..." so the clause reads "...Do not chain
commands with &&, ||, ;, or & unless the user explicitly asks for it. Pipes (|)
are allowed for output transformation (e.g., head, tail, grep). If two
sequential commands are needed, run them in separate tool calls. Chained
commands break the permission allow-list matcher and cause unnecessary
permission prompts."
- Line 10: Add a blank line immediately after each Markdown heading to satisfy
MD022: update AGENTS.md so every heading (e.g., the "## Testing" heading and the
other level-2 headings in the file) is followed by a single empty line before
the next paragraph or content.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 791dc547-b62d-4043-8af9-ec51cf16b4fb

📥 Commits

Reviewing files that changed from the base of the PR and between 25de54c and df1d5e3.

📒 Files selected for processing (1)
  • AGENTS.md

@ejfine ejfine marked this pull request as ready for review March 13, 2026 13:35
@ejfine ejfine requested review from idonaldson and zendern March 13, 2026 13:35
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

♻️ Duplicate comments (1)
AGENTS.md (1)

10-10: ⚠️ Potential issue | 🟡 Minor

Fix MD022 heading spacing (blank line after headings).

Line 10, Line 18, and Line 25 should each be followed by a blank line to satisfy markdownlint.

Proposed markdownlint-compliant fix
 ## Testing
+
 - Always run tests with an explicit path (e.g. uv run pytest tests/unit) — test runners discover all types by default.
@@
 ### Python Testing
+
 - When using `mocker.spy` on a class-level method (including inherited ones), the spy records the unbound call, so assertions need `ANY` as the first argument to match self:  `spy.assert_called_once_with(ANY, expected_arg)`
@@
 ## Tooling
+
 - Always use `uv run python` instead of `python3` or `python` when running Python commands.

Also applies to: 18-18, 25-25

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@AGENTS.md` at line 10, Add a blank line after each Markdown heading in
AGENTS.md to satisfy markdownlint MD022 (e.g., ensure there is an empty line
immediately after the "Testing" heading and after the other headings noted in
the review); update the file so every heading line is followed by a single blank
line, then re-run the linter to confirm the MD022 warning is resolved.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In `@AGENTS.md`:
- Line 10: Add a blank line after each Markdown heading in AGENTS.md to satisfy
markdownlint MD022 (e.g., ensure there is an empty line immediately after the
"Testing" heading and after the other headings noted in the review); update the
file so every heading line is followed by a single blank line, then re-run the
linter to confirm the MD022 warning is resolved.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 75511fff-e719-47c8-9947-1236214fd255

📥 Commits

Reviewing files that changed from the base of the PR and between df1d5e3 and 2f29926.

⛔ Files ignored due to path filters (1)
  • uv.lock is excluded by !**/*.lock
📒 Files selected for processing (4)
  • .devcontainer/devcontainer.json
  • AGENTS.md
  • extensions/context.py
  • pyproject.toml

@ejfine ejfine enabled auto-merge (squash) March 13, 2026 13:42
@zendern
Copy link
Contributor

zendern commented Mar 13, 2026

Better instructions to agents after empirically observing them not doing these things by default

We can see if this helps any. I happened on this article today and we might want to start looking at hooks next

https://dev.to/albert_nahas_cdc8469a6ae8/your-claudemd-instructions-are-being-ignored-heres-why-and-how-to-fix-it-23p6

@ejfine ejfine merged commit 95e0e70 into main Mar 13, 2026
7 checks passed
@ejfine
Copy link
Contributor Author

ejfine commented Mar 13, 2026

Better instructions to agents after empirically observing them not doing these things by default

We can see if this helps any. I happened on this article today and we might want to start looking at hooks next

https://dev.to/albert_nahas_cdc8469a6ae8/your-claudemd-instructions-are-being-ignored-heres-why-and-how-to-fix-it-23p6

I'm sure we're still only scratching the surface, hooks sound like a good next thing. but emprically, these instructions did help (well, the 'stop chaining commands' is still touch and go)---I used them in repos and got claude to be better, and now I'm adding them to the template

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants