diff --git a/.dockerignore b/.dockerignore index b33cd1f032..dc032bc40d 100644 --- a/.dockerignore +++ b/.dockerignore @@ -49,4 +49,5 @@ # ── Re-exclusions inside admitted directories ───────────────────────────────── # Agent instructions and package documentation are never read by a build stage. **/AGENTS.md +**/CLAUDE.md **/docs/ diff --git a/.github/workflows/CLAUDE.md b/.github/workflows/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/.github/workflows/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/docs/CLAUDE.md b/docs/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/docs/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/docs/analysis/CLAUDE.md b/docs/analysis/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/docs/analysis/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/docs/discussions/CLAUDE.md b/docs/discussions/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/docs/discussions/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/docs/issues/open/2003-overhaul-guardrails-and-automation/EPIC.md b/docs/issues/open/2003-overhaul-guardrails-and-automation/EPIC.md index 56f4ff458a..2677574fac 100644 --- a/docs/issues/open/2003-overhaul-guardrails-and-automation/EPIC.md +++ b/docs/issues/open/2003-overhaul-guardrails-and-automation/EPIC.md @@ -199,7 +199,7 @@ Status values: `TODO`, `IN_PROGRESS`, `BLOCKED`, `DONE`. | 20 | #2822 - `wait-for-pr-review`: add a `--gh-command` option to name the GitHub CLI command | `docs/issues/closed/2822-2003-wait-for-pr-review-gh-option/ISSUE.md` | DONE | Enhancement to the #2581 poller: the caller names the command, so no `gh` stand-in on `PATH` is needed, and the identity it runs as is reported. Selects no shared runner, cache or policy engine. Independent of the other poller work; spec PR #2826, implemented by PR #2835. | | 21 | #2866 - Move the agent skills to `.claude/skills/` so Claude Code discovers them | `docs/issues/closed/2866-2003-move-skills-to-claude-skills/ISSUE.md` | DONE | Moves the 53 skills to a flat `.claude/skills//` with an index by area and redirect stubs at the old paths, so Claude Code discovers them. Must merge before the custom-agents migration is implemented, because agent definitions name skills. Selects no shared runner, cache or policy engine. | | 22 | #2873 - Shorten the agent skill descriptions so they fit Claude Code's skill listing budget | `docs/issues/closed/2873-2003-shorten-skill-descriptions/ISSUE.md` | DONE | Follow-up of #2866 (its task T1): shortens the 53 skill descriptions to 200 characters or less so the listing fits its 1% budget, fixes the `write-markdown-docs` description that YAML cuts at a `#`, and adds a `frontmatter-validator` rule. Selects no shared runner, cache or policy engine. Spec PR #2875, implemented by PR #2893. | -| 23 | #2904 - Migrate the custom agents to Claude Code and add an explicit orchestrator | `docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md` | TODO | Replaces the ten Copilot profiles in `.github/agents/` with six Claude Code agents in `.claude/agents/`, led by an `orchestrator` that is the session the contributor talks to. Started agents write JSON reply files validated against a schema; a stop hook holds the task reviewer until its reply is valid. Delivered in small pull requests that merge independently, after #2866. Selects no shared runner, cache or policy engine. | +| 23 | #2904 - Migrate the custom agents to Claude Code and add an explicit orchestrator | `docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md` | IN_PROGRESS | Replaces the ten Copilot profiles in `.github/agents/` with six Claude Code agents in `.claude/agents/`, led by an `orchestrator` that is the session the contributor talks to. Started agents write JSON reply files validated against a schema; a stop hook holds the task reviewer until its reply is valid. Delivered in small pull requests that merge independently, after #2866. Selects no shared runner, cache or policy engine. | Also linked as GitHub sub-issues, outside the order: @@ -459,6 +459,8 @@ For each completed subissue in this EPIC, the default completion policy is: - 2026-11-16 16:11 UTC - AI assistant (Claude Code, Claude Fable 5.2, EPIC #2003 coordinator session) - Replaced the Issue Body Mirror rule with Issue Body Pointer: the issue body must hold only stable content and point to this file. The body itself is not edited by this change. The decision has no GitHub comment; its record is [PR #2887](https://github.com/torrust/torrust-tracker/pull/2887). Decided by the maintainer on 2026-11-16. - 2026-11-16 17:35 UTC - AI assistant (Claude Code, Claude Opus 5.5, issue #2866 session) - Marked row 21 (#2866) DONE and pointed it at `docs/issues/closed/`: PR #2886 merged on 2026-11-16 at 17:34 UTC and closed the issue; the spec is archived by the close-out PR. - 2026-11-17 12:14 UTC - AI assistant (Claude Code, Claude Fable 5.2, issue #2904 session) - Two entries in one. Late entry for row 22 (#2873), which was marked DONE on 2026-11-17 at 08:58 UTC without a log line: implemented by PR #2893, specification archived by the close-out PR #2900. Added row 23 (#2904, migrate the custom agents to Claude Code and add an explicit orchestrator), approved by the maintainer; linking it as a GitHub sub-issue is pending. +- 2026-11-17 17:12 UTC - AI assistant (Claude Code, Claude Fable 5.2, issue #2904 session) - Late entry for a scope change made on 2026-11-17 at 16:07 UTC by pull request #2905, merged at 16:52 UTC: issue #2904 is the one approved exception to the Out of Scope item about named models. The maintainer decided it in the design session of that issue; its record is the entry "Named models in #2904" under Decisions Recorded on This EPIC. A reviewer of pull request #2905 noted the missing line. +- 2026-11-17 17:45 UTC - AI assistant (Claude Code, Claude Fable 5.2, issue #2904 session) - Marked row 23 (#2904) IN_PROGRESS: its specification pull request #2905 merged on 2026-11-17 at 16:52 UTC and task T2 is in pull request #2920. - 2026-11-17 18:39 UTC - AI assistant (Claude Code, Claude Fable 5.2, issue #2360 session) - Late entry for row 13 (#2360), which was marked `BLOCKED` on 2026-11-17 at 18:19 UTC without a log line: on hold by maintainer decision since 2026-11-17. T1 and T2 are done (outcome: Temporary); T3 is deferred until the next maintainer review, when the status of upstream google/zerocopy#3414 is checked again. Recorded by PR #2922. ## Acceptance Criteria diff --git a/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md index 468c1672da..18573fea88 100644 --- a/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md +++ b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md @@ -2,14 +2,14 @@ schema-version: 1 doc-type: issue issue-type: task -status: planned +status: in-progress priority: p1 epic: 2003 github-issue: 2904 spec-path: docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md -branch: "2904-migrate-custom-agents-to-claude-code-spec" +branch: "2904-t2-pointer-claude-md" related-pr: null -last-updated-utc: "2026-11-17 16:07" +last-updated-utc: "2026-11-17 18:34" semantic-links: skill-links: - create-issue @@ -516,8 +516,8 @@ on are merged. | ID | Status | Task | Notes / Expected Output | | --- | ------ | ---- | ----------------------- | -| T1 | TODO | Specification pull request | This specification in `docs/issues/open/`, and a new row in the EPIC's Subissues table | -| T2 | TODO | Pointer `CLAUDE.md` | A root `CLAUDE.md` whose only content is the import of `AGENTS.md` (D11); if scenario M4 shows that a scoped `AGENTS.md` is not loaded, an import-only `CLAUDE.md` beside each of the ten scoped `AGENTS.md` files; scenario M4 recorded | +| T1 | DONE | Specification pull request | This specification in `docs/issues/open/`, and a new row in the EPIC's Subissues table | +| T2 | DONE | Pointer `CLAUDE.md` | A root `CLAUDE.md` whose only content is the import of `AGENTS.md` (D11); if scenario M4 shows that a scoped `AGENTS.md` is not loaded, an import-only `CLAUDE.md` beside each of the ten scoped `AGENTS.md` files; scenario M4 recorded | | T3 | TODO | Reply schema and validator | `docs/schemas/agent-reply-v1.schema.json`; the validator with tests, developed in the progressive loop of the `write-unit-test` skill with a recorded design review per increment, and run by the repository checks; `docs/schemas/README.md` updated (D18) | | T4 | TODO | `pr-review-handler` | `.claude/agents/pr-review-handler.md` with the pinned model; `wait-for-pr-review` and `process-pr-review` say which agent runs a round; the inventory `removed-profile-rules.md` created in this folder with the rules of `copilot-suggestions-handler` (AC6); scenarios M1 to M3 recorded | | T5 | TODO | `task-reviewer` | The agent file with the pinned model and the stop hook (D17), with tests of its limit of 3 refusals; the complexity item in `review-task` (D12); the reply rule in `review-task`, which also says that a reply file satisfies the earlier template's checkpoint (D18); scenario M7 recorded | @@ -525,7 +525,7 @@ on are merged. | T7 | TODO | `pr-reviewer` | The agent file with the pinned model; the reply rule in `review-pr` | | T8 | TODO | `researcher` | The agent file | | T9 | TODO | `orchestrator` | The agent file; `docs/agents/orchestration.md` rewritten for the orchestrator-led flow, with the 3-round limit; the issue template checkpoints; scenario M5 recorded | -| T10 | TODO | End of `.github/agents/` | `.github/agents/` removed, with the rules of the `agent-review-report-contract` check that name the profiles and `docs/templates/AGENT-REVIEW-REPORTS.md`; the rest of that check kept and passing; the one-commit-per-lint rule in `fix-clippy-warnings`; the inventory `removed-profile-rules.md` completed for all ten profiles (AC6); `AGENTS.md`, `docs/agents/README.md`, `docs/templates/AGENT-REVIEW-REPORTS.md`, the `frontmatter-validator` rule and the governance ADR updated; the new ADR, and the ADR-move item added to the scope of the harness-workspace draft (D10) | +| T10 | TODO | End of `.github/agents/` | `.github/agents/` removed, with the rules of the `agent-review-report-contract` check that name the profiles and `docs/templates/AGENT-REVIEW-REPORTS.md`; the rest of that check kept and passing; the one-commit-per-lint rule in `fix-clippy-warnings`; the inventory `removed-profile-rules.md` completed for all ten profiles (AC6); `AGENTS.md`, `docs/agents/README.md`, `docs/templates/AGENT-REVIEW-REPORTS.md`, the `frontmatter-validator` rule and the governance ADR updated, with the line of ADR `20261116082711` that says there is no repository `CLAUDE.md`, which T2 made untrue; the new ADR, and the ADR-move item added to the scope of the harness-workspace draft (D10) | | T11 | TODO | Measurement | Review rounds recorded for the first three pull requests handled by `pr-review-handler` (scenario M6); the pull requests of this issue count | | T12 | TODO | Close-out pull request | Completion review, specification moved to `docs/issues/closed/`, EPIC row `DONE` | @@ -575,7 +575,7 @@ a Conventional Commit message with the narrow affected scope, and sign every com - [x] Folder-style spec drafted in `docs/issues/drafts/2003-migrate-custom-agents-to-claude-code/ISSUE.md` - [x] Spec reviewed and approved by user/maintainer - [x] GitHub issue created and issue number added to this spec -- [ ] Spec-only PR merged into `develop` before implementation +- [x] Spec-only PR merged into `develop` before implementation - [ ] Implementation completed - [ ] Automatic verification completed (`linter all`, relevant tests, and any pre-push checks) - [ ] Manual verification scenarios executed and recorded in issue-local `manual-verification-evidence.md` @@ -598,6 +598,10 @@ a Conventional Commit message with the narrow affected scope, and sign every com - 2026-11-17 13:54 UTC - Claude Code (Claude Fable 5.2) - Addressed Copilot's review `5939656808` on pull request #2905 (two findings): T2 and M4 cover the ten scoped `AGENTS.md` files, and the `agent-review-report-contract` check keeps its pull-request audit rules. - 2026-11-17 15:23 UTC - Claude Code (Claude Fable 5.2) - Addressed the reviews `5939681382` and `5939862849` of `da2ce7` on pull request #2905 (one nit, one minor finding about the audit record): the review of T5 itself runs the `task-reviewer` agent on the T5 branch and writes a reply file, so this issue uses `agent-review-reports.md` for T2 to T4 and reply files for T5 to T12. - 2026-11-17 16:07 UTC - Claude Code (Claude Fable 5.2) - Addressed Copilot's review `5941597022` on pull request #2905 (two minor findings): AC10 exempts the forced run of M7 that ends without a reply file, and the EPIC records this issue's named models (D4, D13) as an approved exception to its Out of Scope item. +- 2026-11-17 17:11 UTC - Claude Code (Claude Fable 5.2) - Pull request #2905 merged on 2026-11-17 at 16:52 UTC. Task T2: added the root `CLAUDE.md` and ran scenario M4. Any `CLAUDE.md` at the root or above stops Claude Code from loading the scoped `AGENTS.md` files, and a root `CLAUDE.md` restores only the root `AGENTS.md`, so the ten scoped pointer files of D11 were added too. With all eleven, the session and a started agent receive the root and the scoped rules in both checkouts. AC12 is met; evidence in `manual-verification-evidence.md` section V4. +- 2026-11-17 17:19 UTC - Claude Code (Claude Fable 5.2) - Independent review of T2 recorded in `agent-review-reports.md` (REVIEW PASSED, two minor findings and four nits). Addressed: the evidence states which probes have recorded tool calls and that the probed files were committed afterwards; `status` is `in-progress` and `branch` names the T2 branch; the T10 row names the ADR line that T2 made untrue; the branch is rebased on `develop`. +- 2026-11-17 17:45 UTC - Claude Code (Claude Fable 5.2) - Addressed the reviews `5943570147` of `da2ce7` and `5943581377` of Copilot on pull request #2920: `.dockerignore` re-excludes the pointer files; the evidence states what probes 1, 2 and 4 show, names its commands as run, and stores every probe's answer in `evidence/m4-probe-answers.md`; T1 is `DONE` and the EPIC row is `IN_PROGRESS`. +- 2026-11-17 18:34 UTC - Claude Code (Claude Fable 5.2) - Addressed the approving review `5944190011` of `da2ce7` on pull request #2920 (two nits): the evidence records the correction to the description of checkout P, and the stored answers say which angle-bracket names are the probes' own. ## Acceptance Criteria @@ -630,7 +634,7 @@ a Conventional Commit message with the narrow affected scope, and sign every com - [ ] AC11: The stop hook of `task-reviewer` refuses to let it finish without a valid reply file, and lets it finish on the fourth attempt, after 3 refusals, reporting that the limit was reached. -- [ ] AC12: The root `CLAUDE.md` contains only the import of `AGENTS.md`, and a rule of a scoped +- [x] AC12: The root `CLAUDE.md` contains only the import of `AGENTS.md`, and a rule of a scoped `AGENTS.md` reaches a session that reads a file in its directory (scenario M4). - [ ] `linter all` exits with code `0` - [ ] Relevant tests pass @@ -661,7 +665,7 @@ Every scenario records the Claude Code version it ran on. | M1 | The agent files load | Start Claude Code with `--debug` in the repository; list the agents; search the debug output for ignored frontmatter | Every agent merged so far is listed; no key is reported as ignored | TODO | `manual-verification-evidence.md` section V1 | | M2 | The pinned model applies | Start `pr-review-handler` from a session running on a different model; record the model named in the agent's transcript file, not the one the agent says it is | The agent ran on the model in its frontmatter, with no fallback | TODO | `manual-verification-evidence.md` section V2 | | M3 | A real review round | On an open pull request with a submitted review, let the session that owns it delegate the round to `pr-review-handler` | Fixes committed and pushed, every thread replied to and then resolved, the audit record updated, `validate-audit-record.py` exits `0`, a short report returned | TODO | `manual-verification-evidence.md` section V3 | -| M4 | `AGENTS.md` reaches the agents | In a checkout with a `CLAUDE.md` in a parent folder, and in one without, ask the session and one started agent which repository rules they were given; then make each read a file in `packages/configuration/` and ask for a rule that only `packages/configuration/AGENTS.md` holds | Both the session and the started agent received the root `AGENTS.md` in both cases, and the scoped rule after reading a file in that directory; each `CLAUDE.md` contains only an import | TODO | `manual-verification-evidence.md` section V4 | +| M4 | `AGENTS.md` reaches the agents | In a checkout with a `CLAUDE.md` in a parent folder, and in one without, ask the session and one started agent which repository rules they were given; then make each read a file in `packages/configuration/` and ask for a rule that only `packages/configuration/AGENTS.md` holds | Both the session and the started agent received the root `AGENTS.md` in both cases, and the scoped rule after reading a file in that directory; each `CLAUDE.md` contains only an import | DONE | `manual-verification-evidence.md` section V4 | | M5 | The orchestrator leads | Start a session as the orchestrator on a small real task, once with `claude --agent orchestrator` and once by telling a normal session to read the file and take the role | It starts the implementer, then the task reviewer; each writes a valid reply file in `agent-replies/`; the implementer starts no agent; questions come back to the contributor through the orchestrator | TODO | `manual-verification-evidence.md` section V5 | | M6 | Review rounds per pull request | For the first three pull requests handled by `pr-review-handler`, count the review rounds with fixes | The counts are recorded with the model of each round, next to the baseline of pull request #2851 (14 rounds, split by model) | TODO | `manual-verification-evidence.md` section V6 | | M7 | The stop hook holds the reviewer | Start `task-reviewer` on a task, first with an instruction that makes it try to finish without a reply file, then normally | The hook refuses the first attempt and names what is missing; the agent then writes a valid reply file and finishes; a forced case shows 3 refusals and then the fourth attempt allowed, with the limit reported | TODO | `manual-verification-evidence.md` section V7 | @@ -692,7 +696,7 @@ None planned. | AC9 | TODO | | | AC10 | TODO | | | AC11 | TODO | | -| AC12 | TODO | | +| AC12 | DONE | `manual-verification-evidence.md` section V4: probes 5 to 12 quote the root heading and the scoped rule in both checkouts, for the session and a started agent; `git ls-files \| grep -E '(^\|/)CLAUDE\.md$' \| xargs cat \| sort -u` prints only `@AGENTS.md` | ## Risks and Trade-offs diff --git a/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/agent-review-reports.md b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/agent-review-reports.md new file mode 100644 index 0000000000..bc3fbe721c --- /dev/null +++ b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/agent-review-reports.md @@ -0,0 +1,49 @@ +--- +semantic-links: + related-artifacts: + - .github/agents/complexity-auditor.agent.md + - .github/agents/task-reviewer.agent.md + - .github/agents/pr-reviewer.agent.md + - docs/agents/orchestration.md +--- + +# Agent Review Reports - Migrate the custom agents to Claude Code and add an explicit orchestrator + +> Append one completed independent-review entry at a time. Do not modify, reorder, or remove +> earlier entries. A correction is a new entry that names the earlier conclusion. + +## Reports + +### 2026-11-17 17:19 UTC - Task reviewer (Claude Code subagent, Claude Opus 5.5, `review-task` skill) + +- Invocation scope: Read-only review of task T2 before its pull request, on branch + `2904-t2-pointer-claude-md`: the root pointer `CLAUDE.md`, the ten scoped pointer files, the + evidence of scenario M4 with the specification updates, and the late EPIC Progress Log line. + The Test Design section of the checklist did not apply; no test changed. +- Inputs: the four commits of the branch; the specification (D11, the T2 rows of the + Implementation Plan and of Commit Points, AC12, M4); `manual-verification-evidence.md`; the + EPIC; the page , which the reviewer fetched. +- Evidence: `git ls-files` lists 11 `AGENTS.md` and 11 `CLAUDE.md` files in the same + directories, and `od -c` shows each `CLAUDE.md` is exactly `@AGENTS.md` and a newline. The + documentation says relative import paths resolve from the file that holds the import, and the + reviewer's own session loaded `docs/CLAUDE.md` with `docs/AGENTS.md`. The step order and + times of the evidence are consistent, and its table matches its conclusion. The subjects are + Conventional Commits with no closing keyword. `linter markdown` and `linter cspell` exited 0. + `git merge-tree --write-tree torrust/develop HEAD` merged with no conflict. +- Findings: + - Minor: ADR `20261116082711` says "there is no repository `CLAUDE.md`", which T2 makes + untrue, and no task says that line is amended. + - Minor: the evidence said a correct quote could not come from reading the file because the + prompt allows one call; only probes 9 to 12 record the tool calls, and probe 3 was neither + recorded at that level nor repeated. + - Nit: "Artifact under test" called the pointer files "added by" the two commits; the probes + ran on the files before they were committed. + - Nit: the evidence commit also ticks the checkpoint "Spec-only PR merged", which its message + does not mention. + - Nit: the frontmatter still had `status: planned` and the specification branch. + - Nit: the branch was 10 commits behind `develop`. +- Verdict: REVIEW PASSED +- Follow-up actions: + - Author, done before the pull request: reworded the two evidence passages; set + `status: in-progress` and the T2 branch; added the ADR line to the T10 row; rebased on + `develop`. The checkpoint nit is left as it is: the tick is true, and it is named here. diff --git a/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/evidence/m4-probe-answers.md b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/evidence/m4-probe-answers.md new file mode 100644 index 0000000000..f65b5febe9 --- /dev/null +++ b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/evidence/m4-probe-answers.md @@ -0,0 +1,173 @@ +# Scenario M4: the answer of each probe + +The `result` field of each probe's output, verbatim except for four path fragments, replaced so +that the contributor's local folder layout is not published: `` and `` +are the two checkouts, `` is checkout P's path below that folder, and `` is the folder above checkout P that holds the +contributor's personal `CLAUDE.md`. The rest of each output is not stored, because it contains +that personal file. See section V4 of `../manual-verification-evidence.md`. + +Two other names in angle brackets are not replacements made here: `` and `` are +abbreviations the probes chose themselves in their answers. Each probe that uses one says which +path it stands for, and only that path was replaced. + +## Probe 1 - checkout P, no pointer file, session + +```text +Q1: NOT LOADED. Only the CLAUDE.md at the Torrust checkouts folder level was given to me, and no root AGENTS.md content appeared in my context. +Q2: NOT LOADED. No `packages/configuration/AGENTS.md` content appeared, even after reading `packages/configuration/Cargo.toml`. +Q3: Only `/CLAUDE.md`. +``` + +## Probe 2 - checkout P, root pointer only, session + +```text +Q1: The root AGENTS.md content was loaded (via the `@AGENTS.md` import in the worktree CLAUDE.md). Its first heading line is: `# Torrust Tracker — AI Assistant Instructions` +Q2: NOT LOADED. Reading `packages/configuration/Cargo.toml` did not bring in a `packages/configuration/AGENTS.md`. +Q3: The files I was given are `/CLAUDE.md`, `/CLAUDE.md` and `/AGENTS.md`. `` is ``. +``` + +## Probe 3 - checkout N, no pointer file, session + +```text +Q1: Yes. The first heading line of the root AGENTS.md is `# Torrust Tracker — AI Assistant Instructions`. +Q2: Yes. The heading of its first rule is `### Rule: Use typed newtypes for domain-constrained configuration fields`. +Q3: The files whose content I was given are: +- `/AGENTS.md` (root, in the initial context) +- `.../torrust-tracker/packages/AGENTS.md` (delivered with the Read result) +- `.../torrust-tracker/packages/configuration/AGENTS.md` (delivered with the Read result) + +I was given no CLAUDE.md file. +``` + +## Probe 4 - checkout N, root pointer only, session + +```text +Q1: Yes. The root AGENTS.md was loaded, and its first heading line is `# Torrust Tracker — AI Assistant Instructions`. +Q2: NOT LOADED. I was not given the content of packages/configuration/AGENTS.md. +Q3: The CLAUDE.md and AGENTS.md files whose content I was given are both in `/`: +- `CLAUDE.md` +- `AGENTS.md` +``` + +## Probe 5 - checkout N, all pointer files, session + +```text +Q1: Yes. The first heading line of the root AGENTS.md is `# Torrust Tracker — AI Assistant Instructions`. +Q2: Yes. The heading of its first rule is `### Rule: Use typed newtypes for domain-constrained configuration fields`. +Q3: I was given the content of these files: +- Root: `CLAUDE.md` (which is only `@AGENTS.md`) and `AGENTS.md`, under `/`. +- `packages/CLAUDE.md` and `packages/AGENTS.md`, under the same root. +- `packages/configuration/CLAUDE.md` and `packages/configuration/AGENTS.md`, under the same root. + +The other untracked `CLAUDE.md` files (`.github/workflows`, `docs`, `docs/analysis`, `docs/discussions`, `docs/issues/open`, `docs/research`, `src`, `tests`) were listed in git status only. Their content was not loaded. +``` + +## Probe 6 - checkout N, all pointer files, started agent + +```text +Q1: Root AGENTS.md was loaded. First heading line: "# Torrust Tracker — AI Assistant Instructions" +Q2: packages/configuration/AGENTS.md was loaded. First rule heading: "### Rule: Use typed newtypes for domain-constrained configuration fields" +Q3: Content given for: CLAUDE.md (root), AGENTS.md (root), packages/CLAUDE.md, packages/AGENTS.md, packages/configuration/CLAUDE.md, packages/configuration/AGENTS.md. The root files were in the initial context. The packages/ and packages/configuration/ files arrived after my Read of packages/configuration/Cargo.toml. Each CLAUDE.md contained only "@AGENTS.md". +``` + +## Probe 7 - checkout P, all pointer files, session + +```text +Q1: Yes. The first heading line of the root `AGENTS.md` is `# Torrust Tracker — AI Assistant Instructions`. + +Q2: Yes. The first rule heading in `packages/configuration/AGENTS.md` is `### Rule: Use typed newtypes for domain-constrained configuration fields`. + +Q3: I was given the content of these seven files: +- `/CLAUDE.md` +- `/CLAUDE.md` +- `/AGENTS.md` +- `/packages/CLAUDE.md` +- `/packages/AGENTS.md` +- `/packages/configuration/CLAUDE.md` +- `/packages/configuration/AGENTS.md` + +`` is ``. The `packages/` and `packages/configuration/` files arrived only after I read `packages/configuration/Cargo.toml`. I was not given the content of the other untracked `CLAUDE.md` files shown in git status (`docs/`, `src/`, `tests/` and similar). +``` + +## Probe 8 - checkout P, all pointer files, started agent + +```text +Q1: Yes. The first heading line of the root AGENTS.md is "# Torrust Tracker — AI Assistant Instructions". +Q2: Yes. The first rule heading in packages/configuration/AGENTS.md is "### Rule: Use typed newtypes for domain-constrained configuration fields". +Q3: Files whose content I was given (all under /): +- CLAUDE.md (the Torrust checkouts folder) +- /CLAUDE.md +- /AGENTS.md +- /packages/CLAUDE.md +- /packages/AGENTS.md +- /packages/configuration/CLAUDE.md +- /packages/configuration/AGENTS.md + +Timing: the root files were in my context at the start. The packages/ and packages/configuration/ files arrived as system reminders after I read packages/configuration/Cargo.toml. I read only that one file, with a single Read call, and used no other tool. +``` + +## Probe 9 - checkout N, all pointer files, session + +```text +Q1: Yes. The first heading line is `# Torrust Tracker — AI Assistant Instructions`. +Q2: Yes. The heading of its first rule is `### Rule: Use typed newtypes for domain-constrained configuration fields`. +Q3: Files whose content I was given: +- `/AGENTS.md` (root, loaded via the root `CLAUDE.md`'s `@AGENTS.md` import) +- `/CLAUDE.md` (root) +- `/packages/CLAUDE.md` +- `/packages/AGENTS.md` +- `/packages/configuration/CLAUDE.md` +- `/packages/configuration/AGENTS.md` + +`` is ``. +``` + +## Probe 10 - checkout N, all pointer files, started agent + +```text +Q1: Yes. The root AGENTS.md was loaded (via the root CLAUDE.md's @AGENTS.md import). Its first heading line is "# Torrust Tracker — AI Assistant Instructions". +Q2: Yes. packages/configuration/AGENTS.md was loaded. The heading of its first rule is "### Rule: Use typed newtypes for domain-constrained configuration fields". +Q3: Root CLAUDE.md and AGENTS.md; packages/CLAUDE.md and packages/AGENTS.md; packages/configuration/CLAUDE.md and packages/configuration/AGENTS.md. All paths are under /. The packages/ and packages/configuration/ files arrived only after my Read of packages/configuration/Cargo.toml. The root pair was loaded at session start. +``` + +## Probe 11 - checkout P, all pointer files, session + +```text +Q1: Not loaded as a file read. Only the root `CLAUDE.md` was loaded, and its content is `@AGENTS.md`. Its content did reach my context via that import, and the first heading line is `# Torrust Tracker — AI Assistant Instructions`. +Q2: Yes, `packages/configuration/AGENTS.md` was given to me, and its first rule heading is `### Rule: Use typed newtypes for domain-constrained configuration fields`. +Q3: Files whose content I was given: +- `/CLAUDE.md` +- `/CLAUDE.md` +- `/AGENTS.md` +- `/packages/CLAUDE.md` +- `/packages/AGENTS.md` +- `/packages/configuration/CLAUDE.md` +- `/packages/configuration/AGENTS.md` + +`` is ``. +``` + +## Probe 12 - checkout P, all pointer files, started agent + +```text +The subagent is still running. I'll print its answer verbatim once it finishes. + +[next result record] + +Q1: Root AGENTS.md was loaded (via CLAUDE.md @AGENTS.md import). First heading line verbatim: "# Torrust Tracker — AI Assistant Instructions" +Q2: packages/configuration/AGENTS.md was loaded. First rule heading verbatim: "### Rule: Use typed newtypes for domain-constrained configuration fields" +Q3: Content given for these files: +- /CLAUDE.md +- /CLAUDE.md +- /AGENTS.md +- /packages/CLAUDE.md +- /packages/AGENTS.md +- /packages/configuration/CLAUDE.md +- /packages/configuration/AGENTS.md + +Note: the root AGENTS.md was loaded at session start, while packages/AGENTS.md, packages/configuration/CLAUDE.md and packages/configuration/AGENTS.md (and packages/CLAUDE.md) arrived only after the Read of packages/configuration/Cargo.toml (nested lazy load). + +[next result record] + +(empty result record) +``` diff --git a/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/manual-verification-evidence.md b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/manual-verification-evidence.md new file mode 100644 index 0000000000..7a4c683af2 --- /dev/null +++ b/docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/manual-verification-evidence.md @@ -0,0 +1,209 @@ +--- +doc-type: manual-verification-evidence +issue-spec: docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/ISSUE.md +last-updated-utc: 2026-11-17 18:34 +--- + +# Manual Verification Evidence + +## Purpose + +Record real, human-oriented verification of the completed behavior. This is +evidence from commands or interactions actually performed against the artifact; +do not invent commands, output, logs, or results. + +Sections are numbered after the scenarios of the specification (V4 is scenario M4). Each task +adds the section of the scenario it records. + +## Environment and Prerequisites + +- Date and time (UTC): 2026-11-17, 16:53 to 17:09 +- Artifact under test: the pointer files of task T2, on top of `develop` at the merge of pull + request #2905. The probes ran on the files before they were committed (written with `printf` + and `cp`, see the steps); they were committed unchanged afterwards by + `docs(agents): [#2904] add a root CLAUDE.md that only imports AGENTS.md` and + `docs(agents): [#2904] add an import-only CLAUDE.md beside each scoped AGENTS.md`. +- Operating system / environment: Linux 7.0.0-43-generic; Claude Code 2.1.318 (`claude --version`); + every probe session ran on `claude-sonnet-5-5` (the `init` record of its output). +- Prerequisites and setup performed: two checkouts of the same commit. + - **Checkout P (a `CLAUDE.md` in a parent folder):** the contributor's working checkout, a + git worktree inside another checkout of the repository. A `CLAUDE.md` with personal + instructions exists four folders above it, and the enclosing checkout's `AGENTS.md` three + folders above it. `ls ~/.claude/CLAUDE.md` reported no such file. + - **Checkout N (no `CLAUDE.md` above):** made with + `git clone -q --no-hardlinks --depth 1 "file://" /m4-clone/torrust-tracker` + (the `file://` form, so `--depth` applies; `git log --oneline -1` in it printed the merge of + pull request #2905). The parent folders were checked with + `p=$(dirname $C); for i in 1 2 3 4 5 6 7 8 9 10; do ls $p/CLAUDE.md $p/AGENTS.md 2>/dev/null; [ "$p" = "/" ] && break; p=$(dirname $p); done`, + where `$C` is the clone; it printed nothing. The pointer files were copied into it with `cp` + before the probes that need them. + +## Verification Processes + +### V4 - `AGENTS.md` reaches the agents (scenario M4) + +- Goal: show that the session and an agent it starts receive the root `AGENTS.md`, and the rules + of a scoped `AGENTS.md` after reading a file in its directory, with and without a `CLAUDE.md` + in a parent folder; and decide whether the scoped pointer files of D11 are needed. +- Initial state: `develop` at the merge of pull request #2905, with no `CLAUDE.md` in the + repository. +- Status: `DONE` + +#### Steps Performed + +Each probe is one non-interactive Claude Code session started in the checkout: + +```text +claude -p "" --tools --output-format json < /dev/null +``` + +The session prompt, used with `--tools Read`: + +```text +This is a test of which instruction files were loaded into your context. Use the Read tool exactly once, on the file packages/configuration/Cargo.toml. Use no other tool and read no other file. Then answer these three questions from your context only, in three lines: +Q1: Were you given the content of this repository's root AGENTS.md? If yes, quote its first heading line verbatim. If not, answer NOT LOADED. +Q2: Were you given the content of packages/configuration/AGENTS.md? If yes, quote verbatim the heading of its first rule (a line starting with "### Rule:"). If not, answer NOT LOADED. +Q3: List the paths of every CLAUDE.md or AGENTS.md file whose content you were given. +``` + +The agent prompt, used with `--tools Read Agent`, wraps the session prompt: + +```text +This is a test of which instruction files a started agent receives. Start exactly one subagent of type general-purpose with the Agent tool. Give it exactly the task between the markers, and nothing else. Do not read any file yourself. When it answers, print its answer verbatim and add nothing. +---BEGIN TASK--- + +---END TASK--- +``` + +The expected quotes are the first line of `AGENTS.md` +(`# Torrust Tracker — AI Assistant Instructions`) and the first rule heading of +`packages/configuration/AGENTS.md` +(`### Rule: Use typed newtypes for domain-constrained configuration fields`). `--tools Read` +leaves the session no tool but `Read`. The prompt asks for one call on `Cargo.toml`, but nothing +enforces the number of calls: that the session made that one call and no other is recorded only +for probes 9 to 12 (see the tool calls below), which repeat probes 5 to 8. + +The probes ran one at a time, in this order. Times are UTC: the modification time of the probe's output file +(`TZ=UTC ls -l --time-style=+%H:%M:%S`) for probes 1 and 2, `date -u` at the end of the probe for probes 3 to 8, and `date -u` at its start +and end for probes 9 to 12. + +1. Probe 1, checkout P, no pointer file, session prompt. Output written at 16:54:58. +2. Wrote the root `CLAUDE.md` in checkout P (`printf '@AGENTS.md\n' > CLAUDE.md`). +3. Probe 2, checkout P, root pointer only, session prompt. Output written at 16:55:15. +4. Wrote a `CLAUDE.md` with the same content beside each of the ten scoped `AGENTS.md` files in + checkout P. +5. Created checkout N from the commit without pointer files. +6. Probe 3, checkout N, no pointer file, session prompt. Ended 17:06:33. +7. Copied the root `CLAUDE.md` into checkout N. +8. Probe 4, checkout N, root pointer only, session prompt. Ended 17:06:52. +9. Copied the ten scoped `CLAUDE.md` files into checkout N; `git status --short | wc -l` printed 11. +10. Probes 5 to 8, all pointer files, with `--output-format json`: checkout N session (ended + 17:07:02), checkout N agent (17:07:19), checkout P session (17:07:30), checkout P agent + (17:07:45). +11. Probes 9 to 12, the same four cases again with `--output-format stream-json --verbose`, to + record the tool calls: checkout N session (17:08:05 to 17:08:15), checkout N agent (17:08:15 + to 17:08:30), checkout P session (17:08:30 to 17:08:41), checkout P agent (17:08:41 to + 17:08:57). + +#### Observed Result + +Answers to Q1 and Q2, and the files each probe listed for Q3. "root pair" is the root `CLAUDE.md` +and `AGENTS.md`; "scoped pairs" is the `CLAUDE.md` and `AGENTS.md` of `packages/` and of +`packages/configuration/`. + +| Probe | Checkout | Pointer files | Who answered | Q1 root `AGENTS.md` | Q2 scoped rule | Q3 files given | +| ----- | -------- | ------------- | ------------ | ------------------- | -------------- | -------------- | +| 1 | P | none | session | NOT LOADED | NOT LOADED | only the parent folder's `CLAUDE.md` | +| 2 | P | root only | session | quoted | NOT LOADED | the parent folder's `CLAUDE.md`, root pair | +| 3 | N | none | session | quoted | quoted | root `AGENTS.md`, `packages/AGENTS.md`, `packages/configuration/AGENTS.md` | +| 4 | N | root only | session | quoted | NOT LOADED | root pair | +| 5, 9 | N | all | session | quoted | quoted | root pair, scoped pairs | +| 6, 10 | N | all | started agent | quoted | quoted | root pair, scoped pairs | +| 7, 11 | P | all | session | quoted | quoted | the parent folder's `CLAUDE.md`, root pair, scoped pairs | +| 8, 12 | P | all | started agent | quoted | quoted | the parent folder's `CLAUDE.md`, root pair, scoped pairs | + +Every "quoted" answer gave the expected line verbatim. Answers of probes 1, 2 and 4, verbatim: + +```text +Probe 1 +Q1: NOT LOADED. Only the CLAUDE.md at the Torrust checkouts folder level was given to me, and no root AGENTS.md content appeared in my context. +Q2: NOT LOADED. No `packages/configuration/AGENTS.md` content appeared, even after reading `packages/configuration/Cargo.toml`. + +Probe 2 +Q1: The root AGENTS.md content was loaded (via the `@AGENTS.md` import in the worktree CLAUDE.md). Its first heading line is: `# Torrust Tracker — AI Assistant Instructions` +Q2: NOT LOADED. Reading `packages/configuration/Cargo.toml` did not bring in a `packages/configuration/AGENTS.md`. + +Probe 4 +Q1: Yes. The root AGENTS.md was loaded, and its first heading line is `# Torrust Tracker — AI Assistant Instructions`. +Q2: NOT LOADED. I was not given the content of packages/configuration/AGENTS.md. +``` + +Tool calls recorded by probes 9 to 12 (`tool_use` records of the stream; "main" is the session, +"agent" is a record with a parent tool call): + +```text +Probe 9 main: Read packages/configuration/Cargo.toml +Probe 10 main: Agent (subagent_type general-purpose) + agent: Read packages/configuration/Cargo.toml + agent: SubagentHandback +Probe 11 main: Read packages/configuration/Cargo.toml +Probe 12 main: Agent (subagent_type general-purpose) + agent: Read packages/configuration/Cargo.toml + agent: SubagentHandback +``` + +The started agents of probes 6, 8, 10 and 12 said the root pair was in their context at the +start and the scoped pairs arrived after their `Read` call. The answer of probe 12's agent to Q1 +and Q2, verbatim: + +```text +Q1: Root AGENTS.md was loaded (via CLAUDE.md @AGENTS.md import). First heading line verbatim: "# Torrust Tracker — AI Assistant Instructions" +Q2: packages/configuration/AGENTS.md was loaded. First rule heading verbatim: "### Rule: Use typed newtypes for domain-constrained configuration fields" +``` + +The answer of every probe is stored in [`evidence/m4-probe-answers.md`](evidence/m4-probe-answers.md), +with four local path fragments replaced. The rest of each output is not stored: it contains the +contributor's personal `CLAUDE.md` from the parent folder. + +#### Conclusion + +The scenario's expected result is met with all eleven pointer files: in both checkouts the +session and the started agent received the root `AGENTS.md`, and the scoped rule after reading +a file in `packages/configuration/`. Every `CLAUDE.md` in the repository contains only the +import `@AGENTS.md` (`git ls-files | grep -E '(^|/)CLAUDE\.md$' | xargs cat | sort -u` prints +that one line). + +The probes also settle the question D11 left to this task: + +- Without any `CLAUDE.md` above or in the checkout, Claude Code loads the root and the scoped + `AGENTS.md` files by itself (probe 3). +- With a `CLAUDE.md` in a parent folder and none in the repository, it loads neither (probe 1). +- Any `CLAUDE.md` at the root or above stops the scoped `AGENTS.md` files from loading (probes + 1, 2 and 4). A root `CLAUDE.md` restores only the root `AGENTS.md`: in checkout P the scoped + ones stay unloaded (probe 2, as in probe 1), and in checkout N, where they loaded without it + (probe 3), it stops them (probe 4). So the scoped pointer files are needed, as the reviewer of + pull request #2905 reported. + +Limits of this evidence: the answers are what each model reported about its own context. For +probes 9 to 12 the recorded tool calls show the quoted lines were not read from the files. For +probes 1 to 8 no tool calls were recorded, so a quote there could in principle come from an extra +`Read` call; this matters most for probe 3, the one positive result behind "loads by itself", +which was not repeated; its answer text is in the stored file. The NOT LOADED answers of probes 1, 2 and 4 do not depend on it. Only +`packages/configuration/` was probed, and the other eight scoped directories rely on the same +mechanism; the behaviour is that of Claude Code 2.1.318. + +## Failures and Follow-up + +- A first attempt at steps 5 to 10 did not run: `git clone --local` failed with "Invalid + cross-device link", and a shell loop in the same command then ran without end and was stopped. + No probe ran in that attempt. The clone was repeated with `--no-hardlinks`. +- Correction to the description of checkout P. The first version of this document, in + `docs(issues): [#2904] record scenario M4 and mark task T2 done`, said the personal `CLAUDE.md` + was three folders above checkout P and did not say that checkout P is a git worktree inside + another checkout of the repository. It is four folders above, and the enclosing checkout's + `AGENTS.md` is three folders above. The Environment section was corrected in + `docs(issues): [#2904] correct the M4 evidence and store every probe's answer`. No probe was + rerun and the conclusions do not depend on it: the enclosing `AGENTS.md` was not loaded in + probe 1, and no probe listed it. +- In probe 12 the session printed "The subagent is still running" before it printed the agent's + answer; the answer recorded above is the one it printed afterwards. diff --git a/docs/issues/open/CLAUDE.md b/docs/issues/open/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/docs/issues/open/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/docs/pr-reviews/pr-2905-review/PR-REVIEW.md b/docs/pr-reviews/pr-2905-review/PR-REVIEW.md index e7fc5ac9b2..c567d27486 100644 --- a/docs/pr-reviews/pr-2905-review/PR-REVIEW.md +++ b/docs/pr-reviews/pr-2905-review/PR-REVIEW.md @@ -1,7 +1,7 @@ --- pr-number: 2905 pr-url: https://github.com/torrust/torrust-tracker/pull/2905 -last-updated-utc: "2026-11-17 16:14" +last-updated-utc: "2026-11-17 17:59" --- @@ -17,7 +17,7 @@ Source: pull-request reviews and inline review threads for https://github.com/to The PR author owns this tracked audit record. Reviewers, including repository review agents, deliver findings through GitHub and have no repository-artifact obligation. -- Post-merge workflow approval: N/A +- Post-merge workflow approval: https://github.com/torrust/torrust-tracker/pull/2905#issuecomment-6956439261 (retrospective record: the maintainer gave the approval in the working session on 2026-11-17 at about 16:44 UTC, and created this comment at 17:59:16Z) @@ -62,6 +62,9 @@ F13 collides with the audit's F13), on the head that carried the round 4 audit, Round 7 is Copilot's review `5941597022` (COMMENTED, F17 and F18, reviewer-provided IDs, which do not collide; its comments carry `[Minor]` brackets, which are used) and the approving review `5941484820` of `da2ce7` (F19, audit-local ID; the reviewer's own F15 collides with the audit's F15), both on the head that carried the round 6 audit. +Round 8 is the review `5942183537` of `da2ce7` (DISMISSED, F20 and F21, audit-local IDs; the reviewer's own F17 and F18 +collide with the audit's F17 and F18), on the head that carried the round 7 fixes, before the round 7 audit. Both are +handled after the merge, in pull request #2920. | Finding ID | Review finding reference | Author class | Severity | Category | Relationship | Disposition | Thread state | | ---------- | ------------------------ | ------------ | -------- | -------- | ------------ | ----------- | ------------ | @@ -85,6 +88,8 @@ ID; the reviewer's own F15 collides with the audit's F15), both on the head that | F17 | `review-finding:pr-2905-f17` | Copilot | Minor | correctness | ORIGINAL | FIXED | RESOLVED | | F18 | `review-finding:pr-2905-f18` | Copilot | Minor | documentation | ORIGINAL | FIXED | RESOLVED | | F19 | `review-finding:pr-2905-f19` | Human | Minor | documentation | ORIGINAL | FIXED | RESOLVED | +| F20 | `review-finding:pr-2905-f20` | Human | Nit | documentation | ORIGINAL | FOLLOW_UP | OPEN | +| F21 | `review-finding:pr-2905-f21` | Human | Minor | documentation | ORIGINAL | FIXED | RESOLVED | ## Finding Details @@ -348,6 +353,32 @@ ID; the reviewer's own F15 collides with the audit's F15), both on the head that - Follow-up PR URL: N/A - Reply URL: https://github.com/torrust/torrust-tracker/pull/2905#discussion_r4601867922 +### F20 - The EPIC's progress log has no line for this exception + +- PR number: 2905 +- Source review ID: 5942183537 +- Reviewer finding ID: F17 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2905#discussion_r4602381116 +- Concern: The entry "Named models in #2904" changes the EPIC's scope, but the EPIC's Progress Log had no line for it. The EPIC template asks for one line per meaningful update. +- Solution: The maintainer chose to merge pull request #2905 without another push and to carry this to the first implementation pull request of issue 2904. That pull request, #2920, adds a late Progress Log line naming the exception, its record and who decided it, in `docs(issues): [#2904] log the named-model exception in the EPIC progress log`. Until it merges the line is not on `develop`, so the disposition is `FOLLOW_UP` and the thread stays open; the row becomes `FIXED` and the thread is resolved after the merge. +- Current-tree verification: `grep -n "Late entry for a scope change" docs/issues/open/2003-overhaul-guardrails-and-automation/EPIC.md` prints the new line on the branch of pull request #2920, after the 12:14 entry of 2026-11-17; `git grep -c "Late entry for a scope change" torrust/develop -- docs/issues/open/2003-overhaul-guardrails-and-automation/EPIC.md` prints nothing. `linter markdown` and `linter cspell` passed. +- Resolution reference: https://github.com/torrust/torrust-tracker/pull/2905#discussion_r4602755221 +- Follow-up PR URL: https://github.com/torrust/torrust-tracker/pull/2920 +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2905#discussion_r4602755221 + +### F21 - Three answered threads still need audit rows + +- PR number: 2905 +- Source review ID: 5942183537 +- Reviewer finding ID: F18 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2905#discussion_r4602381129 +- Concern: At the head the reviewer read, the audit record ended at F16 and CC1, while the round 6 finding and the two findings of the automated review `5941597022` had replies and no rows. +- Solution: The three rows (F17, F18 and F19) were already committed when the review was written and reached the pull request with the round 7 audit commit, pushed minutes later. The reviewer's next review, on that head, says this finding is fixed by it. This row and F20 were carried to pull request #2920 by the maintainer's choice. +- Current-tree verification: `grep -c "^| F17 \|^| F18 \|^| F19 \|^| F20 \|^| F21 "` on this record prints 5. +- Resolution reference: `docs(pr-reviews): [#2904] record round 7 in the review audit of PR #2905` +- Follow-up PR URL: https://github.com/torrust/torrust-tracker/pull/2920 +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2905#discussion_r4602403441 + ## Processing Log - 2026-11-17 12:58 UTC - Started audit, after the seven replies, because it holds their URLs. Review `5938631990` of `da2ce7` was submitted at 12:45:09Z (forge `submitted_at`) with seven findings, F1 to F7. The seven fixes and a plan and log follow-up were committed between 12:48:39Z and 12:55:23Z (`git log --format=%cI`, in UTC), one commit per finding, and pushed; `git ls-remote` showed the fork branch at the local head before the replies. The seven replies were posted between 12:57:58Z and 12:58:14Z (forge `created_at`). The body of issue 2904 was edited for F5 before the replies. @@ -367,6 +398,9 @@ ID; the reviewer's own F15 collides with the audit's F15), both on the head that - 2026-11-17 16:12 UTC - The contributor (maintainer of the repository) answered the round-limit question for Copilot's review `5941597022` with "Fix as round 7", although `josecelano` (15:33:57Z) and `da2ce7` (15:35:36Z) had posted `ACK` for the head that carried the round 6 audit (forge `created_at`); the push moves the head past those comments. - 2026-11-17 16:12 UTC - Round 7: Copilot's review `5941597022` (submitted 15:42:17Z, forge `submitted_at`) with two findings, F17 and F18, and the approving review `5941484820` of `da2ce7` with one finding about the order of round 6, recorded as F19. The reply to F19 was posted at 15:38:07Z (forge `created_at`) with no commit, and its thread was left unresolved until this row existed. The two fixes for F17 and F18 were committed at 16:08:15Z and 16:08:48Z (`git log --format=%cI`, in UTC) and pushed; `git ls-remote` showed the fork branch at the local head at 16:11:45Z (`date -u`). The two replies were posted after that, at 16:12:04Z and 16:12:06Z (forge `created_at`). - 2026-11-17 16:14 UTC - `validate-audit-record.py --pr-number 2905 --base torrust/develop`, with its `gh` calls made through `gh-bot`, exited 0 (20 rows, 0 failures). The unresolved threads were the three of round 7, each with the contributor's reply as its last comment. Resolved the two threads of F17 and F18 by their thread IDs, their fixes being on the pull request; a GraphQL refresh showed 1 unresolved thread, the one of F19. Its row records `RESOLVED` as the state it takes once this record is pushed: it is not resolved at the time of this entry, and is resolved by its thread ID after the push. +- 2026-11-17 17:23 UTC - Round 8, after the merge: the review `5942183537` of `da2ce7` (submitted 16:16:56Z, forge `submitted_at`) on the head between the two pushes of round 7, with two findings, recorded as F20 and F21. The reply to F21 was posted at 16:18:40Z and the reply to F20 at 16:44:18Z (forge `created_at`), after the maintainer chose to merge without another push. Pull request #2905 was merged at 16:52:36Z (forge `mergedAt`) with both threads unresolved. The fix for F20 was committed on the branch of pull request #2920 and pushed before this entry; `git ls-remote` showed the fork branch at the local head. The two threads are not resolved at the time of this entry: they are resolved by their thread IDs after this record is pushed. +- 2026-11-17 17:50 UTC - Correction for the round 8 entry, after the reviews `5943570147` of `da2ce7` and `5943581377` of Copilot on pull request #2920. That entry said both threads would be resolved after the push, and both were, at about 17:28Z, with F20 recorded `FIXED`/`RESOLVED`. For F20 that was wrong: its fix is only on the branch of pull request #2920, and `process-pr-review` (Reviews Submitted After Merge, steps 5 and 6) keeps such a row `FOLLOW_UP`/`OPEN` until the follow-up merges. The thread of F20 was reopened by its thread ID at 17:48:28Z (`date -u` after the call) and its row corrected. F21 stays `FIXED`/`RESOLVED`: its fix was on `develop` at the merge. Step 2 of the same section asks for the maintainer's approval as a durable comment URL in the Ownership section before any mutating action. That was not done: the choice was made in the working session, and the round 8 changes were made without the comment. The field stays `N/A` until the maintainer posts the comment; it is then recorded as a retrospective approval with both times. +- 2026-11-17 17:59 UTC - The maintainer posted the approval of the post-merge work as a comment on pull request #2905 at 17:59:16Z (forge `created_at`, author `josecelano`). It is a retrospective record: it states that the approval was given in the working session at about 16:44 UTC, before the round 8 changes. Its URL is recorded in the Ownership section. diff --git a/docs/pr-reviews/pr-2920-review/PR-REVIEW.md b/docs/pr-reviews/pr-2920-review/PR-REVIEW.md new file mode 100644 index 0000000000..8ec50a64da --- /dev/null +++ b/docs/pr-reviews/pr-2920-review/PR-REVIEW.md @@ -0,0 +1,312 @@ +--- +pr-number: 2920 +pr-url: https://github.com/torrust/torrust-tracker/pull/2920 +last-updated-utc: "2026-11-17 19:17" +--- + + + +# PR #2920 Review Audit + +Source: pull-request reviews and inline review threads for https://github.com/torrust/torrust-tracker/pull/2920. + + + +## Ownership + +The PR author owns this tracked audit record. Reviewers, including repository review agents, +deliver findings through GitHub and have no repository-artifact obligation. + +- Post-merge workflow approval: N/A + + + +## Status Values + +- Relationship: `ORIGINAL`, `RE_RAISE_OF:` +- Disposition: `FIXED`, `NO_ACTION`, `SUPERSEDED`, `FOLLOW_UP` +- Thread state: `OPEN`, `RESOLVED`, `NON_RESOLVABLE`, `SUPERSEDED`. `OPEN` applies prospectively + to audits created or updated for approved follow-up work; historical audits remain valid without + bulk migration. +- Severity: `Blocker`, `Major`, `Minor`, `Nit`, `Suggestion`; append `(inferred)` when derived + from free prose. +- Author class: `Copilot`, `Human`, `Unknown` +- Category: `link-integrity`, `formatting`, `metadata`, `testing`, `correctness`, + `documentation`, `maintainability`, `security`, `other` +- An outdated thread whose concern was fixed is `FIXED`/`RESOLVED`, even when GitHub marks the + original thread outdated after the push. For in-PR feedback, use `NO_ACTION`/`SUPERSEDED` only + for a duplicate, superseded, or no-change concern. A post-merge `NO_ACTION` requires maintainer + approval to decline the follow-up work. +- When the current identity cannot resolve a thread (`viewerCanResolve` is `false`), keep the + disposition established from the current tree and record `Thread state=OPEN`. The reviewer or PR + author resolves it; permission says nothing about whether the concern was fixed. + +## Findings + +Round 1 is two reviews on the first head that carried the post-merge audit rows of pull request 2905: the approving review +`5943570147` of `da2ce7` (F1 to F8, reviewer-provided IDs) and Copilot's review `5943581377` (COMMENTED, two findings +with its own IDs F1 and F2, which collide with the first review's and are recorded as F9 and F10). F8 and F10 were processed after the others, once the maintainer had posted the comment they ask for; see the Processing Log. +Round 2 is the approving review `5944190011` of `da2ce7` (F11 and F12, audit-local IDs; the reviewer numbers them F22 +and F23, continuing the count of pull request 2905's record), on the head that carried the last audit commit of round 1. +Round 3 is the approving review `5944671302` of `da2ce7` (F13, audit-local ID; the reviewer numbers it F24), on the head +that carried the round 2 audit. +Round 4 is the approving review `5944877623` of `da2ce7` (F14, audit-local ID; the reviewer numbers it F25), on the head +that carried the round 3 audit. +Round 5 is the approving review `5953723621` of `da2ce7` (F15, audit-local ID; the reviewer numbers it F26), on the head +rebased onto `d8e14450d`. + +| Finding ID | Review finding reference | Author class | Severity | Category | Relationship | Disposition | Thread state | +| ---------- | ------------------------ | ------------ | -------- | -------- | ------------ | ----------- | ------------ | +| F1 | `review-finding:pr-2920-f1` | Human | Minor | maintainability | ORIGINAL | FIXED | RESOLVED | +| F2 | `review-finding:pr-2920-f2` | Human | Minor | correctness | ORIGINAL | FIXED | RESOLVED | +| F3 | `review-finding:pr-2920-f3` | Human | Minor | documentation | ORIGINAL | FIXED | RESOLVED | +| F4 | `review-finding:pr-2920-f4` | Human | Nit | correctness | ORIGINAL | FIXED | RESOLVED | +| F5 | `review-finding:pr-2920-f5` | Human | Suggestion | documentation | ORIGINAL | FIXED | RESOLVED | +| F6 | `review-finding:pr-2920-f6` | Human | Minor | documentation | ORIGINAL | FIXED | RESOLVED | +| F7 | `review-finding:pr-2920-f7` | Human | Minor | correctness | ORIGINAL | FIXED | RESOLVED | +| F8 | `review-finding:pr-2920-f8` | Human | Minor | documentation | ORIGINAL | FIXED | RESOLVED | +| F9 | `review-finding:pr-2920-f9` | Copilot | Minor | correctness | RE_RAISE_OF:F7 | FIXED | RESOLVED | +| F10 | `review-finding:pr-2920-f10` | Copilot | Minor | documentation | RE_RAISE_OF:F8 | FIXED | RESOLVED | +| F11 | `review-finding:pr-2920-f11` | Human | Nit | documentation | ORIGINAL | FIXED | RESOLVED | +| F12 | `review-finding:pr-2920-f12` | Human | Nit | documentation | ORIGINAL | FIXED | RESOLVED | +| F13 | `review-finding:pr-2920-f13` | Human | Nit | correctness | ORIGINAL | FIXED | RESOLVED | +| F14 | `review-finding:pr-2920-f14` | Human | Nit | correctness | ORIGINAL | FIXED | RESOLVED | +| F15 | `review-finding:pr-2920-f15` | Human | Suggestion | documentation | ORIGINAL | FIXED | RESOLVED | + +## Finding Details + +### F1 - The pointer files enter the container build context + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F1 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463621 +- Concern: The pointer files under `src/`, `tests/`, `packages/` and `packages/configuration/` are in directories the container build admits. `.dockerignore` re-excludes `**/AGENTS.md` there, because no build stage reads agent instructions and an edit to one must not invalidate the source `COPY` layers (decision 3 of ADR `20260929183441`); the pointer files were not re-excluded. +- Solution: `.dockerignore` re-excludes `**/CLAUDE.md` on the line after `**/AGENTS.md`, under the same comment. The ADR is not edited: the new line follows the reason it gives. +- Current-tree verification: `grep -n -A3 "Re-exclusions inside admitted" .dockerignore` shows `**/AGENTS.md` and `**/CLAUDE.md` on consecutive lines. `linter all` passed in the pre-commit checks of the commit. +- Resolution reference: `build(container): [#2904] keep the pointer CLAUDE.md files out of the build context` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603595739 + +### F2 - The conclusion about probes 1 and 2 says more than they show + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F2 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463631 +- Concern: The evidence said a root `CLAUDE.md` alone stops the scoped `AGENTS.md` files "with a parent `CLAUDE.md` (probe 2) and without one (probe 4)". Probe 1 already answers NOT LOADED for the scoped rule in checkout P, so there the root pointer leaves them unloaded; only checkout N (probes 3 and 4) shows it stopping them. The Progress Log line and the description repeated the wording. +- Solution: The conclusion says any `CLAUDE.md` at the root or above stops the scoped files (probes 1, 2 and 4) and a root pointer restores only the root file, with the two checkouts told apart. The Progress Log line of `ISSUE.md` and the pull request description use the same wording. +- Current-tree verification: Read the conclusion of section V4 against the table of probes after the change. `grep -rn "with and without a" docs/issues/open/2904-2003-migrate-custom-agents-to-claude-code/` prints only lines about the two checkouts of the scenario, none about the root pointer stopping the scoped files. +- Resolution reference: `docs(issues): [#2904] correct the M4 evidence and store every probe's answer` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603596181 + +### F3 - Two status cells lag the state this pull request records + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F3 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463640 +- Concern: The pull request ticks the checkpoint for the merged specification pull request, but the T1 row stayed `TODO`; the frontmatter moved to `in-progress` while row 23 of the EPIC's Subissues table stayed `TODO`. +- Solution: T1 is `DONE` in the Implementation Plan, in `docs(issues): [#2904] correct the M4 evidence and store every probe's answer`. Row 23 of the EPIC is `IN_PROGRESS`, with a Progress Log line. +- Current-tree verification: `grep -n "^| T1 " ISSUE.md` in the issue folder shows `DONE`; `grep -n "^| 23 " EPIC.md` in the EPIC folder shows `IN_PROGRESS`. +- Resolution reference: `docs(issues): [#2904] mark the EPIC row of issue 2904 in progress` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603596608 + +### F4 - Two named commands do not produce what the evidence attributes to them + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F4 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463654 +- Concern: Plain `ls -l` cannot give a time to the second in UTC; `git clone --no-hardlinks --depth 1` of a local path ignores `--depth`; the parent-folder loop was described without its command. +- Solution: The evidence names the commands as run: `TZ=UTC ls -l --time-style=+%H:%M:%S`; the clone with the `file://` form, which the evidence had dropped and with which `--depth` applies; and the loop with its command and that it printed nothing. The same paragraph is corrected in one more place: the personal file is four folders above checkout P, not three. +- Current-tree verification: Compared each command in the Environment section and the steps of section V4 with the commands of the session that ran them. `linter markdown` and `linter cspell` passed. +- Resolution reference: `docs(issues): [#2904] correct the M4 evidence and store every probe's answer` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603597014 + +### F5 - Store each probe's answer text, not only the summary table + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F5 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463663 +- Concern: The template asks for the outputs a reviewer needs in the issue folder; the reason given for not storing them covers the full output, not its answer field. Probe 3, the one positive result behind "loads by itself", gains most. +- Solution: `evidence/m4-probe-answers.md` holds the answer field of all twelve probes, verbatim except for four local path fragments that are replaced and named at the top of the file. The evidence links it. +- Current-tree verification: `grep -c "^## Probe " evidence/m4-probe-answers.md` in the issue folder prints 12. `grep -c "/home/\|/tmp/"` on the same file prints 0. +- Resolution reference: `docs(issues): [#2904] correct the M4 evidence and store every probe's answer` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603597441 + +### F6 - The description no longer matches the branch at this head + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F6 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463667 +- Concern: "Files touched" omitted the audit record of pull request 2905, "addressed in the last commit" pointed at the wrong commit after a later push, and "the two audit rows follow in a later commit" described a commit already on the branch. +- Solution: The description was edited at 17:54:15Z (forge `updated_at`): it lists every changed file, names the commit of the independent review by its subject, and says the two audit rows are on the branch. No file changes. +- Current-tree verification: `gh pr view 2920 --json body` read after the edit against `git diff --name-only torrust/develop...HEAD`. +- Resolution reference: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603597887 +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603597887 + +### F7 - F20 of pull request 2905 is recorded fixed while its fix rides in this open follow-up + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F7 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463673 +- Concern: The audit record of pull request 2905 recorded its post-merge finding F20 as `FIXED`/`RESOLVED` and its thread was resolved, while the fix is only on this branch. `process-pr-review` (Reviews Submitted After Merge, steps 5 and 6) keeps such a row `FOLLOW_UP`/`OPEN` until the follow-up merges. +- Solution: In the audit record of pull request 2905, F20 is `FOLLOW_UP`/`OPEN` with the reply on its thread as resolution reference, and a correction entry in its Processing Log names the wrong entry. Its thread was reopened by its thread ID at 17:48:28Z. +- Current-tree verification: `grep -n "^| F20 " docs/pr-reviews/pr-2905-review/PR-REVIEW.md` shows `FOLLOW_UP | OPEN`. A GraphQL read of the threads of pull request 2905 shows the thread of comment 4602381116 unresolved. `validate-audit-record.py --pr-number 2905` exited 0 (22 rows). +- Resolution reference: `docs(pr-reviews): [#2904] keep finding F20 of PR #2905 open until its follow-up merges` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603598317 + +### F8 - The Ownership section of the audit of pull request 2905 has no post-merge approval + +- PR number: 2920 +- Source review ID: 5943570147 +- Reviewer finding ID: F8 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603463689 +- Concern: Round 8 of the audit record of pull request 2905 is feedback unprocessed at merge, yet its Ownership section read `Post-merge workflow approval: N/A`. Step 2 of `process-pr-review` (Reviews Submitted After Merge) asks for the maintainer's approval as a durable comment URL before any mutating action; chat-only approval does not satisfy it. +- Solution: The maintainer posted the approval as a comment on pull request 2905 at 17:59:16Z. The Ownership section of that audit record holds its URL as a retrospective record, with the original approval time (about 16:44 UTC, in the working session) and the comment's creation time, and its Processing Log has an entry for it. The round 8 changes were made before the comment existed; the log of that record says so. +- Current-tree verification: `grep -n "Post-merge workflow approval" docs/pr-reviews/pr-2905-review/PR-REVIEW.md` shows the comment URL and both times. `gh api repos/torrust/torrust-tracker/issues/comments/6956439261` shows the author `josecelano` and `created_at` 17:59:16Z. `validate-audit-record.py --pr-number 2905` exited 0 (22 rows). +- Resolution reference: `docs(pr-reviews): [#2904] record the maintainer's approval of the post-merge work of PR #2905` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603701212 + +### F9 - Keep F20 pending until the follow-up merges + +- PR number: 2920 +- Source review ID: 5943581377 +- Reviewer finding ID: F1 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603473090 +- Concern: The same concern as F7, raised by Copilot's review 48 seconds later: F20 of pull request 2905 is marked `FIXED`/`RESOLVED` while its change exists only in this open pull request. +- Solution: The change recorded under F7. +- Current-tree verification: The checks recorded under F7. +- Resolution reference: `docs(pr-reviews): [#2904] keep finding F20 of PR #2905 open until its follow-up merges` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603599135 + +### F10 - Record the authorization URL for this post-merge handoff + +- PR number: 2920 +- Source review ID: 5943581377 +- Reviewer finding ID: F2 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603473174 +- Concern: The same concern as F8, raised by Copilot's review 49 seconds later. It suggests filling the field with the reply `discussion_r4602755221` on pull request 2905. +- Solution: The change recorded under F8. The suggested URL is not used: the contributor account wrote that reply, and the skill asks for the maintainer's approval. +- Current-tree verification: The checks recorded under F8. +- Resolution reference: `docs(pr-reviews): [#2904] record the maintainer's approval of the post-merge work of PR #2905` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603701767 + +### F11 - Checkout P's description changed in substance without a note in the evidence + +- PR number: 2920 +- Source review ID: 5944190011 +- Reviewer finding ID: F22 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603897988 +- Concern: Round 1 changed the description of checkout P (the personal file four folders above, not three; a worktree inside another checkout whose `AGENTS.md` is three folders above), and the evidence did not say it was a correction. The change appeared only in the reply to F4 and partly in its row. +- Solution: Failures and Follow-up of the evidence has a line for the correction: what the first version said, what is true, the commit that corrected the Environment section, that no probe was rerun, and why the conclusions do not depend on it. +- Current-tree verification: `grep -n "Correction to the description of checkout P" manual-verification-evidence.md` in the issue folder prints the line. Read the Q3 answers of the six probes run in checkout P (probes 1, 2, 7, 8, 11 and 12) in `evidence/m4-probe-answers.md`: probe 1 lists only the personal `CLAUDE.md` of the parent folder, the other five list that file and files of checkout P, and none of the six lists an `AGENTS.md` above checkout P. `linter markdown` and `linter cspell` passed. +- Resolution reference: `docs(issues): [#2904] note the corrected description of checkout P in the M4 evidence` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4604090320 + +### F12 - The answers file uses two placeholders its header does not name + +- PR number: 2920 +- Source review ID: 5944190011 +- Reviewer finding ID: F23 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4603898005 +- Concern: The header of `evidence/m4-probe-answers.md` names four replaced path fragments, but the answers also contain `` and ``, so a reader cannot tell which angle-bracket names are replacements. +- Solution: The header says that `` and `` are abbreviations the probes chose themselves, that each probe using one says which path it stands for, and that only that path was replaced. +- Current-tree verification: `sed -n '1,13p' evidence/m4-probe-answers.md` in the issue folder shows the new paragraph. `grep -c ""` and `grep -c ""` on that file print 16 and 8 lines, one of each being the new paragraph. +- Resolution reference: `docs(issues): [#2904] note the corrected description of checkout P in the M4 evidence` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4604090708 + +### F13 - Two current-tree verifications of the round 2 rows do not show what they state + +- PR number: 2920 +- Source review ID: 5944671302 +- Reviewer finding ID: F24 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4604278993 +- Concern: The verification of F12 gave the counts 15 and 7 for the two placeholder names; at the head they are 16 and 8, the earlier counts being from before the fix. The verification of F11 cited a `grep -c` for a literal local path, which prints 0 whatever the probes answered because every path in the answers file is replaced, and it named a local folder the answers file withholds. +- Solution: The line of F12 gives 16 and 8 and says one of each is the new paragraph. The line of F11 cites the Q3 answers of the six probes of checkout P instead of the path search. The Processing Log has a correction entry. +- Current-tree verification: `grep -c ""` and `grep -c ""` on `evidence/m4-probe-answers.md`, run again after the fix of round 2, print 16 and 8. A script listed the `AGENTS.md` and `CLAUDE.md` paths in the Q3 answers of probes 1, 2, 7, 8, 11 and 12: each list holds the parent folder's `CLAUDE.md` or files of checkout P only. A search of `docs/` for the local folder name the earlier line contained finds no match. +- Resolution reference: `docs(pr-reviews): [#2904] correct two verification lines in the review audit of PR #2920` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4604343733 + +### F14 - The corrected line of F11 says more than probe 1's answer shows + +- PR number: 2920 +- Source review ID: 5944877623 +- Reviewer finding ID: F25 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4604444973 +- Concern: The verification line of F11, as corrected in round 3, said each of the six answers of checkout P lists the parent folder's personal file and files of checkout P. Probe 1 lists only the parent folder's file: it ran before any pointer file. The clause the finding needs, that none of the six lists an `AGENTS.md` above checkout P, holds for all six. +- Solution: The line of F11 says that probe 1 lists only the parent folder's file, that the other five list it and files of checkout P, and that none of the six lists an `AGENTS.md` above checkout P. The Processing Log has a correction entry. +- Current-tree verification: A script over the Q3 answers of probes 1, 2, 7, 8, 11 and 12 in `evidence/m4-probe-answers.md` printed, per probe, whether the answer names the parent folder's file and whether it names a file of checkout P: both for probes 2, 7, 8, 11 and 12, and the parent folder's file only for probe 1. +- Resolution reference: `docs(pr-reviews): [#2904] say what probe 1 lists in the review audit of PR #2920` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4604513267 + +### F15 - Record the rebases in the Processing Log + +- PR number: 2920 +- Source review ID: 5953723621 +- Reviewer finding ID: F26 +- Source URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4611573587 +- Concern: Two rebases set every committer time to 2026-11-18 09:02, so the `git log --format=%cI` the log entries name no longer prints the times they give, and the review threads cite commit ids the rebases replaced. Nothing in the log names the rebases. +- Solution: A Processing Log entry names both rebases with their times and bases, the EPIC conflict that required the first, and the `git log --format=%aI` form that prints the times of the earlier entries; it says the ids cited in the threads are from before the rebases and that each commit's subject identifies it. +- Current-tree verification: `git log --format=%aI` over the branch printed 18:00:55Z, 18:35:10Z, 18:58:46Z and 19:13:28Z for the four commits whose times the log entries give, the same times the entries state. +- Resolution reference: `docs(pr-reviews): [#2904] record the two rebases in the review audit of PR #2920` +- Follow-up PR URL: N/A +- Reply URL: https://github.com/torrust/torrust-tracker/pull/2920#discussion_r4611619528 + +## Processing Log + +- 2026-11-17 17:55 UTC - Started audit. +- 2026-11-17 17:55 UTC - Round 1: the approving review `5943570147` of `da2ce7` (submitted 17:42:25Z) with eight findings and Copilot's review `5943581377` (submitted 17:43:14Z, forge `submitted_at`) with two. The `ACK` comments of `josecelano` (17:36:20Z and 17:43:52Z) and `da2ce7` (17:42:30Z, forge `created_at`) name the head these reviews read; the fixes move the head past them. The fixes were committed between 17:48:20Z and 17:51:07Z (`git log --format=%cI`, in UTC) and pushed; `git ls-remote` showed the fork branch at the local head at 17:53:45Z (`date -u`). The description was edited at 17:54:15Z, and the ten replies were posted between 17:54:17Z and 17:54:39Z (forge `created_at`), after the push. +- 2026-11-17 17:55 UTC - Two findings of round 1 are answered and not processed: the reviewer's F8 (comment `4603463689`) and Copilot's F2 (comment `4603473174`), both about the missing post-merge approval URL in the audit record of pull request 2905. The field needs a durable comment by the maintainer, who has been asked for it. They have no row yet and their threads stay unresolved. Copilot's suggestion to use the reply `4602755221` is not followed: the contributor account wrote that reply. +- 2026-11-17 17:56 UTC - `validate-audit-record.py --pr-number 2920 --base torrust/develop`, with its `gh` calls made through `gh-bot`, exited 0 (8 rows, 0 failures). Resolved the eight threads of F1 to F7 and F9 by their thread IDs, each with the contributor's reply as its last comment and its fix on the pull request. A GraphQL refresh showed 2 unresolved threads: the two about the approval URL, which wait for the maintainer's comment. +- 2026-11-17 18:04 UTC - The maintainer posted the approval comment on pull request #2905 at 17:59:16Z (forge `created_at`). The two findings left from round 1 are recorded as F8 and F10. Their fix was committed at 18:00:55Z (`git log --format=%cI`, in UTC) and pushed; `git ls-remote` showed the fork branch at the local head at 18:03:26Z (`date -u`). Each thread already had a reply from 17:54 that said the fix was pending; the two replies that name the fix were posted at 18:03:39Z and 18:03:42Z (forge `created_at`), after the push. +- 2026-11-17 18:04 UTC - `validate-audit-record.py --pr-number 2920 --base torrust/develop`, with its `gh` calls made through `gh-bot`, exited 0 (10 rows, 0 failures). Resolved the two threads of F8 and F10 by their thread IDs; a GraphQL refresh showed 0 unresolved threads. +- 2026-11-17 18:39 UTC - Round 2: the approving review `5944190011` of `da2ce7` (submitted 18:21:14Z, forge `submitted_at`) with two nits, recorded as F11 and F12. The reviewer's `ACK` comment (18:21:18Z, forge `created_at`) names the head it read; the fix moves the head past it. The contributor (maintainer of the repository) chose to fix them in this pull request. The fix was committed at 18:35:10Z (`git log --format=%cI`, in UTC) and pushed; `git ls-remote` showed the fork branch at the local head at 18:38:31Z (`date -u`). The two replies were posted at 18:38:46Z and 18:38:48Z (forge `created_at`), after the push. +- 2026-11-17 18:39 UTC - `validate-audit-record.py --pr-number 2920 --base torrust/develop`, with its `gh` calls made through `gh-bot`, exited 0 (12 rows, 0 failures). Resolved the two threads of F11 and F12 by their thread IDs; a GraphQL refresh showed 0 unresolved threads. +- 2026-11-17 18:58 UTC - Correction to the Current-tree verification lines of F11 and F12, after the review `5944671302` of `da2ce7`. F12 gave the counts 15 and 7, taken before the fix added one line with each name; at the fix they are 16 and 8. F11 cited a `grep -c` for a local path that prints 0 whatever the probes answered, because every path in the answers file is replaced, and it named a local folder the answers file withholds; it now cites the Q3 answers of the six probes of checkout P, read in the file. +- 2026-11-17 19:01 UTC - Round 3: the approving review `5944671302` of `da2ce7` (submitted 18:55:59Z, forge `submitted_at`) with one nit, recorded as F13. The reviewer's `ACK` comment (18:56:04Z, forge `created_at`) names the head it read; the fix moves the head past it. The fix was committed at 18:58:46Z (`git log --format=%cI`, in UTC) and pushed; `git ls-remote` showed the fork branch at the local head before the reply. The reply was posted at 19:01:47Z (forge `created_at`), after the push. +- 2026-11-17 19:02 UTC - `validate-audit-record.py --pr-number 2920 --base torrust/develop`, with its `gh` calls made through `gh-bot`, exited 0 (13 rows, 0 failures). Resolved the thread of F13 by its thread ID; a GraphQL refresh showed 0 unresolved threads. +- 2026-11-17 19:13 UTC - Second correction to the Current-tree verification line of F11, after the review `5944877623` of `da2ce7`. The corrected line said each of the six answers of checkout P lists the parent folder's file and files of checkout P; probe 1 lists only the parent folder's file, because it ran before any pointer file existed. The line now says so. The reply of round 3 on the thread of F13 repeated the wrong wording. +- 2026-11-17 19:16 UTC - Round 4: the approving review `5944877623` of `da2ce7` (submitted 19:10:53Z, forge `submitted_at`) with one nit, recorded as F14. The reviewer's `ACK` comment (19:10:57Z, forge `created_at`) names the head it read; the fix moves the head past it. The fix was committed at 19:13:28Z (`git log --format=%cI`, in UTC) and pushed; `git ls-remote` showed the fork branch at the local head before the reply. The reply was posted at 19:16:20Z (forge `created_at`), after the push. +- 2026-11-17 19:17 UTC - `validate-audit-record.py --pr-number 2920 --base torrust/develop`, with its `gh` calls made through `gh-bot`, exited 0 (14 rows, 0 failures). Resolved the thread of F14 by its thread ID; a GraphQL refresh showed 0 unresolved threads. +- 2026-11-18 09:21 UTC - Two rebases onto `develop`, each keeping every commit. The first, at 2026-11-17 21:30 UTC onto `d24297c23` (the merge of pull request #2922), was required: that pull request changed the same two places of the EPIC file as this one, `last-updated-utc` and the end of its Progress Log. The resolution keeps the later `last-updated-utc` and orders the log lines by time. The second, at 2026-11-18 09:02 UTC onto `d8e14450d` (the merge of pull request #2932), brings in the fix for the nightly toolchain failure of the `OS Compatibility` check, unrelated to this pull request; `git range-diff` showed every commit unchanged. Each rebase reset the committer time of every commit, so `git log --format=%cI` now prints 2026-11-18 09:02 for all of them. The commit times given in the entries above are author times: `git log --format=%aI` prints them. The commit ids cited in the review threads and replies name commits from before the rebases; each of those commits keeps its Conventional Commit subject, which identifies it on the current branch. +- 2026-11-18 09:24 UTC - Round 5: the approving review `5953723621` of `da2ce7` (submitted 09:19:55Z, forge `submitted_at`) with one suggestion, recorded as F15; Copilot's review `5953709053` (09:19:03Z) on the same head recommends approval with no findings. The reviewer's `ACK` comment (09:19:59Z, forge `created_at`) names the head it read; the fix moves the head past it. The fix is the entry above, committed at 09:20:49Z (`git log --format=%aI`, in UTC) and pushed; `git ls-remote` showed the fork branch at the local head at 09:23:46Z (`date -u`). The reply was posted at 09:23:58Z (forge `created_at`), after the push. This is the fifth round of fixes on this pull request. +- 2026-11-18 09:25 UTC - `validate-audit-record.py --pr-number 2920 --base torrust/develop`, with its `gh` calls made through `gh-bot`, exited 0 (15 rows, 0 failures). Resolved the thread of F15 by its thread ID; a GraphQL refresh showed 0 unresolved threads. + + + +## Completion Rules + +- Re-derive the reply claim against the current tree before replying or resolving a thread. +- Reply on every resolvable thread before resolving it. +- For an outdated thread whose concern was fixed, record `Disposition=FIXED` and + `Thread state=RESOLVED`, even if GitHub marks the thread outdated after the push. For a + duplicate, superseded, or no-change in-PR thread, reply exactly + `Superseded by : .`, record `Disposition=NO_ACTION` and + `Thread state=SUPERSEDED`, then resolve it. A post-merge `NO_ACTION` requires maintainer + approval to decline the follow-up work. When the current identity cannot resolve a thread + (`viewerCanResolve` is `false`), still reply, keep the disposition established from the current + tree, and record `Thread state=OPEN`; the reviewer or PR author resolves it. +- A consolidated PR conversation response may cover multiple review rounds only when it names + every review ID and every finding ID with its disposition and resolution reference. Record its + durable URL in each related row. +- Cite a fix by its unique Conventional Commit subject or durable reply URL, never by a branch SHA + that can change after a rebase. +- Refresh review threads using GraphQL and confirm that no unresolved actionable thread remains. diff --git a/docs/research/CLAUDE.md b/docs/research/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/docs/research/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/packages/CLAUDE.md b/packages/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/packages/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/packages/configuration/CLAUDE.md b/packages/configuration/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/packages/configuration/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/project-words.txt b/project-words.txt index 995b02ffad..7d97687107 100644 --- a/project-words.txt +++ b/project-words.txt @@ -48,6 +48,7 @@ Glrg Graphviz Grcov HDRINCL +Handback Hydranode ICASE IPPROTO @@ -291,6 +292,7 @@ gpgsign gzprintf gzvprintf gzwrite +hardlinks hasher healthcheck heaptrack diff --git a/src/CLAUDE.md b/src/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/src/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/tests/CLAUDE.md b/tests/CLAUDE.md new file mode 100644 index 0000000000..43c994c2d3 --- /dev/null +++ b/tests/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md