Skip to content

docs(agents): rules and skills from the 2026-10-31 session retro - #12493

Merged
MarkusNeusinger merged 4 commits into
mainfrom
docs/session-retro-2026-10-31
Oct 31, 2026
Merged

MarkusNeusinger merged 4 commits into
mainfrom
docs/session-retro-2026-10-31

Conversation

@MarkusNeusinger

Copy link
Copy Markdown
Owner

Summary

  • Watcher scripts end on their own. watch-deploys.sh exits 0 with no deploy for <sha> after 6 empty polls (157 s measured on 523199b, which triggered no deploy), now passes --project=anyplot (the project guide's rule; a wrong default project would otherwise read as "no deploy"), and exits 2 at once when gcloud builds list fails. watch-checks.sh waits 90 polls (about 45 minutes) and its TIMEOUT line names the checks still pending. Both caps are stated in open-pr sections 3a and 4.
  • Rules and skills from the retro's findings (owner-approved list, items A1 to A14 and B15 to B20): CLAUDE.md gets the delegate stall check with a post-compaction re-check, a classifier denial that is final for every agent of the session, the first Copilot review at about 5 minutes, and merges only on a named OK (mirrored in copilot-instructions.md); open-pr gets a hadolint row (CI's 2.15.1, threshold warning), tests for new code before the PR opens (the codecov triage folded into section 1), the 16 real check names, the GraphQL requestReviews mechanic, the nvm prefix for site-smoke, a pull --ff-only of the shared checkout and a once-per-session worktree report; zweitmeinung gets the 60 KB diff rule, the --attach path gotcha, ledger-measured costs and the root-owned-files cleanup; verify-core the system-python3 gotcha; guardrails.md the delegation, denial, Console-wizard and stalled-delegate sections.
  • Recipes that lived only in chat: the single-library impl-generate.yml dispatch with its optional inputs (docs/workflows/overview.md), the eval-matrix forms real runs used (agents/README.md), and the describe, edit, import route for a second-generation Cloud Build trigger (agentic/docs/project-guide.md). Every gate command that runs ruff now names the dev extra.

Decisions taken within the brief:

  • The trigger route went into the project guide's deployment section, next to the existing "Checking whether something actually deployed"; infra/ holds only Cloudflare.
  • The hadolint row covers all five Dockerfiles CI lints, not only the renderer and agents ones. "Must print nothing" became "no warning or error line": agents/Dockerfile and toolchain.Dockerfile print info lines (DL3059, DL3066) on main today, below CI's threshold.
  • --extra dev went into every skill, command and doc that runs ruff (also docs/development.md, project-guide.md, copilot-instructions.md, the audit and test commands); historical plans under agentic/specs/ and agentic/audits/ and the CI workflow (which syncs --extra dev) stay as they are.
  • The classifier-denial rule has no mirror in copilot-instructions.md: the classifier is a Claude Code harness mechanism, and that file carries no external-writes rule to extend.
  • The Gemini cost lines in guardrails.md were updated with the same ledger figures, so the skill and the guardrails agree.
  • agents/README.md said --thinking-budget takes 0 to 4,096; matrix.py caps it at 8,192 (MAX_THINKING_BUDGET). Fixed while there.

Plan

N/A. The source is the retro of session 402df83f (2026-10-28 to 2026-10-31), sections 3, 4 and 6: ranked findings, proposed changes, and the first-try accuracy table of documented commands.

Test plan

  • watch-deploys.sh 523199b36 (a .github/workflows/ merge): no deploy for 523199b, exit 0 after 157 s; f356a57b1 the same; e9b11e373 (two deploys): ALL DEPLOYS FINISHED for e9b11e3, 0 not SUCCESS, exit 0 after 32 s
  • watch-checks.sh 12487: exits at once, ALL 16 CHECKS FINISHED on 3a6d00a04, 0 not green; the TIMEOUT name parsing checked on sample lines
  • The worktree report and the pull --ff-only guard run read-only against the shared checkout; the git diff exclude pathspec and the hadolint command run locally (all five Dockerfiles exit 0)
  • RequestReviewsInput lists botIds (GraphQL introspection); the Copilot bot id BOT_kgDOCnlnWA read from feat(ci): Claude credential switch (subscription/oidc/api) + per-implementation daily regen #12487's review
  • uv run --extra dev ruff check . && uv run --extra dev ruff format --check .; uv run python -m tools.changelog check --base origin/main
  • Gemini 3.8 Flash pre-PR check ($0.38): 6 findings, 1 real (detached worktrees missing from the report) fixed in 39f906e; botIds and the hadolint entrypoint were false positives (verified), the rest pre-existing or no false result

https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8

MarkusNeusinger and others added 2 commits October 31, 2026 23:55
Applies the owner-approved findings of the retro of session 402df83f
(2026-10-28 to 2026-10-31):

- watch-deploys.sh ends with "no deploy for <sha>" after 6 empty polls,
  passes --project=anyplot, and exits 2 when gcloud fails;
  watch-checks.sh waits 90 polls and names the pending checks.
- open-pr: hadolint gate for Dockerfiles, tests for new code before the
  PR opens (codecov triage folded in), the real check names, Copilot
  latency of about 5 minutes, the GraphQL requestReviews mechanic, the
  nvm prefix for site-smoke, a pull of the shared checkout after a
  merge, and a report of worktrees whose branch is gone.
- zweitmeinung: attach a diff over about 60 KB, how --attach resolves
  paths, measured Gemini costs, cleanup of root-owned files.
- CLAUDE.md: delegate stall check and post-compaction re-check, a
  classifier denial is final for every agent, first Copilot review at
  about 5 minutes, merges only on a named OK (mirrored in
  copilot-instructions.md).
- guardrails.md: one builder per scope and one message per round, the
  denial incident, the Console-wizard pattern, the stalled-delegate
  incident and recipe.
- Recipes: single-library impl-generate dispatch, eval-matrix forms,
  the second-generation trigger import route.
- uv run --extra dev ruff wherever a skill, command or doc runs ruff.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8
Fixes from the Gemini Flash pre-PR check.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8
Copilot AI lite review requested due to automatic review settings October 31, 2026 23:03

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The Codecov guidance incorrectly treats every red patch check as requiring a test, conflicting with the documented exception for live DB/HTTP flows handled by /verify-api.

1 open issue
What changed in this PR

This pull request documents lessons from the 2026-10-31 session retro across agent guidance, workflow procedures, verification skills, and PR watcher scripts.

Changes:

  • Documents implementation dispatches, evaluation commands, Cloud Build trigger updates, and Ruff requirements.
  • Adds guidance for delegate stalls, worktree reporting, Copilot reviews, Dockerfile linting, Gemini reviews, and verification.
  • Adds bounded deployment and check watchers with clearer failure and timeout reporting.
File Description
docs/​workflows/​overview.md Documents single-library implementation dispatches and inputs.
docs/​development.md Updates Ruff commands to include the dev extra.
CLAUDE.md Adds delegate, review, denial, and merge-authorization guidance.
changelog.d/​session-retro-rules.md Records the session-retro workflow and documentation changes.
agents/​README.md Documents evaluation commands and corrects the thinking-budget limit.
agentic/​docs/​project-guide.md Updates Ruff guidance and documents Cloud Build trigger procedures.
agentic/​commands/​update.md Updates implementation lint commands.
agentic/​commands/​test.md Updates documented test and formatting commands.
agentic/​commands/​regen.md Updates regeneration lint commands.
agentic/​commands/​refactor.md Updates refactoring lint guidance.
agentic/​commands/​pull_request.md Clarifies PR attribution and commit-trailer handling.
agentic/​commands/​audit/​backend-auditor.md Updates the backend audit Ruff command.
agentic/​commands/​audit.md Updates audit baseline and autofix commands.
agentic/​commands/​agentic.md Updates audit-agent Ruff commands.
.github/​copilot-instructions.md Mirrors merge guidance and Ruff command updates.
.claude/​skills/​zweitmeinung/​SKILL.md Adds large-diff attachment, cleanup, and cost guidance.
.claude/​skills/​verify-core/​SKILL.md Updates Ruff guidance and documents the Python-version gotcha.
.claude/​skills/​verify-api/​SKILL.md Updates API verification Ruff commands.
.claude/​skills/​open-pr/​SKILL.md Expands PR gates, review mechanics, watcher guidance, and worktree procedures.
.claude/​skills/​open-pr/​scripts/​watch-deploys.sh Adds project scoping, bounded polling, and failure handling.
.claude/​skills/​open-pr/​scripts/​watch-checks.sh Extends the timeout and reports pending check names.
.claude/​skills/​gemini-task/​SKILL.md Updates Gemini verification commands.
.claude/​guardrails.md Records delegation, permission-denial, Console setup, and stall-handling guidance.

This pull request is ready to be approved.

Review effort: Lite

Comment thread .claude/skills/open-pr/SKILL.md Resolved
Copilot review on #12493.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8
@MarkusNeusinger
MarkusNeusinger merged commit 4845d0c into main Oct 31, 2026
16 checks passed
@MarkusNeusinger
MarkusNeusinger deleted the docs/session-retro-2026-10-31 branch October 31, 2026 23:15
MarkusNeusinger added a commit that referenced this pull request Nov 1, 2026
## Summary
- Main is red since #12493: it added the `.claude/guardrails.md` section
"Long-running work reports progress proactively" without registering it
in `tests/unit/test_agent_instructions.py`, so
`test_every_companion_section_is_registered` fails (seen on #12490's CI
run).
- #12493's CI never ran that test: "Run Tests" only starts for Python,
config, workflow and prompt changes, and the PR changed only instruction
files. `ci-tests.yml` now also runs the tests for `CLAUDE.md`,
`AGENTS.md`, `.github/copilot-instructions.md`, `.claude/guardrails.md`,
`.claude/skills/` and `agentic/commands/`, which
`tests/unit/test_agent_instructions.py` and `tests/unit/skills` read.
- Registers the new section with three CLAUDE.md anchors (never let the
user ask, the 30-minute stall rule, the post-compaction re-check) and
the classifier-denial rule under the external-writes section.

## Plan
N/A (follow-up to #12493)

## Test plan
- [x] `uv run --extra dev --extra test pytest
tests/unit/test_agent_instructions.py tests/unit/skills
tests/unit/workflows -n auto`: 1,319 passed
- [x] The new filter matches `CLAUDE.md`, `.claude/guardrails.md`, a
skill and a command, and not `docs/index.md` or `app/` (dry run of the
grep)
- [x] `tools.changelog check --base origin/main` passes
- [ ] CI: this PR changes a workflow and a test, so "Run Tests" runs and
must be green

https://claude.ai/code/session_01H7HSkGyea1k2v293XiAMo8

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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