Repository navigation
docs(issues): [#2392] add test isolation EPIC and subissue specs - #2397
Conversation
Add the EPIC and specifications for torrust#2393 (parallel test port allocation races, with its reproduction evidence), torrust#2394 (shared test resource audit), torrust#2395 (E2E runner dynamic host ports), and torrust#2396 (unique tracker image tag per CI run). Related to torrust#2392, torrust#2393, torrust#2394, torrust#2395, torrust#2396
Record the new parent EPIC in the torrust#1419 specification. Editing an open spec requires v1 frontmatter, so migrate it: add schema-version, set status to blocked (AC8a waits on torrust#1488), quote scalar values, drop trailing slashes, and replace the issue and PR URLs with an issue reference. Related to torrust#1419, torrust#2392
…ssue specs Related to torrust#2393, torrust#2394, torrust#2395, torrust#2396
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Copilot review overview
Review effort: Lite
Findings: 1
Open (2)
What changed in this PR
Adds a new “Test Isolation” EPIC (#2392) and four new sub-issue specifications (#2393–#2396), plus links the existing open issue #1419 into the EPIC.
Changes:
- Introduces EPIC #2392 with scope, isolation rules, delivery phases, and subissue table.
- Adds specs for four subissues: port allocation race bug (#2393), shared resource audit (#2394), dynamic E2E host ports (#2395), and per-run CI image tagging (#2396).
- Updates #1419 frontmatter to schema v1 and marks it blocked while adding the parent EPIC reference.
| File | Description |
|---|---|
| docs/issues/open/2392-test-isolation/EPIC.md | Adds the Test Isolation EPIC definition, subissues, phases, and rules. |
| docs/issues/open/2393-2392-test-port-allocation-races/ISSUE.md | Adds the bug spec for port allocation race conditions and the fix plan. |
| docs/issues/open/2393-2392-test-port-allocation-races/manual-verification-evidence.md | Adds initial reproduction evidence for the port allocation races. |
| docs/issues/open/2394-2392-audit-shared-test-resources/ISSUE.md | Adds the audit spec/inventory plan for shared resources impacting test isolation. |
| docs/issues/open/2395-2392-e2e-runner-dynamic-host-ports/ISSUE.md | Adds the spec to move E2E runner to Docker-assigned host ports with discovery/tests. |
| docs/issues/open/2396-2392-e2e-unique-tracker-image-tag/ISSUE.md | Adds the spec to use per-run Docker image tags in CI with always-run cleanup. |
| docs/issues/open/1419-allow-multiple-integration-tests-at-main-app-level/ISSUE.md | Migrates frontmatter to v1 and links #1419 to EPIC #2392. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Quote last-updated-utc in the torrust#2393 manual verification evidence to match the new issue specs (review-finding:pr-2397-f2). Manual verification evidence has no v1 frontmatter profile, so schema-version is not added.
Audit Copilot review 5368546961: F1 (issue reference in related-artifacts) is a no-change finding because v1 frontmatter accepts only issue references, not URLs; F2 (unquoted evidence timestamp) is fixed.
Record resolution of Copilot's two addressed review threads after confirming that no unresolved actionable threads remain.
|
ACK 8913c80 |
da2ce7
left a comment
There was a problem hiding this comment.
Reviewed at 8913c806e55eab72215d68245defe25376baea0f (round 1, post-merge). Recomputed from the bytes at this head.
Label: POST_MERGE_FINDINGS — this PR merged at 2026-10-01T06:55:49Z as f6346f323 before this review was written; nothing below asks for remediation, and process-pr-review § "Reviews Submitted After Merge" governs any follow-up.
The PR's audit record docs/pr-reviews/pr-2397-review/PR-REVIEW.md uses audit-local F<ordinal> IDs ending at F2, so new loop findings start at loop F3; record findings are cited as record F1/F2.
What the PR is. Six Conventional Commits ec80aa0fb..8913c806e (cdf7aa899 EPIC and four subissue specs, 5636b9df8 link #1419, 3ae3ab728 record PR #2397 in the subissue specs, 2e68daec8 quote the #2393 evidence timestamp, 135d062b6/8913c806e the audit record); 8 files, +1320/−9. The merge tree of f6346f323 equals the head tree; develop (86392041d) differs from the head only in Cargo.lock (#2400), so every finding below is live on develop.
Shape. The frontmatter validator is Rust; its rules (profile.rs key lists, syntax.rs value syntax, repository.rs spec-path, lifecycle and reference resolution) were emulated with a standard-library script: zero diagnostics on all seven spec files. validate-audit-record.py ran offline against the captured comments with --base ec80aa0fb: exit 0, 2 rows, 3 log entries.
| Spec | Keys/values | last-updated-utc |
spec-path |
Parent line | Folder | Sections |
|---|---|---|---|---|---|---|
| EPIC #2392 | 9/9 EPIC keys, planned |
quoted | = path | n/a | 2392-test-isolation |
all EPIC.md sections |
| #2393 | 12/12, bug, epic: 2392 |
quoted | = path | L39 | 2393-2392-… |
all ISSUE.md sections, bug sections link fix-bug |
| #2394 | 12/12, task, epic: 2392 |
quoted | = path | L28 | 2394-2392-… |
all |
| #2395 | 12/12, task, epic: 2392 |
quoted | = path | L34 | 2395-2392-… |
all |
| #2396 | 12/12, task, epic: 2392 |
quoted | = path | L30 | 2396-2392-… |
all |
| #1419 (edited) | v1 migration, blocked, epic: 2392 |
quoted | = path | L35 | legacy name kept | unchanged |
Test-suite claims (all true at head): fixed E2E host ports src/console/ci/e2e/runner.rs:98-102, with the code-review note at :90; random tracker_ names tracker_container.rs:115-118; 0.0.0.0→127.0.0.1 logs_parser.rs:106; qBittorrent host port 0 in compose.qbittorrent-e2e.*.yaml and docker compose port at compose.rs:150-151; random project names qbittorrent_e2e/runner.rs:104; tags torrust-tracker:local container.yaml:121,128,136,140,144,148 and torrust-tracker:e2e-local testing.yaml:231,240,244,248,252; runner default tag runner.rs:39; security-scan.yaml:30 ubuntu-latest; fixed ports tests/metrics/fixed_ports.rs:46-58 (17091-17094); CLI precedence ports base_source_precedence.rs:11-13 (43152-43154); release-then-bind axum-http-server/src/server.rs:678-680 and UDP udp-server/src/server/mod.rs:200-202; #2386, #2132 and #2298 citations match their files.
Links. Every repository path in frontmatter and body resolves at head; every issue #n maps to the folder with that number (#2388/#2390 are the merges 9d840f55d/4d64d3c34); the EPIC table lists #2393-#2396 plus #1419 with paths and statuses matching each frontmatter. The #1419 edit migrates to v1, adds epic: 2392 and replaces the #1488/#1993 URLs with "issue #1488", the only issue form syntax.rs:14-18,37-39 accepts.
Audit record. The 19-field roster and order match process-pr-review and the template; Ownership, Status Values and Completion Rules are verbatim; review IDs, reply threads (in_reply_to_id) and isResolved agree with the evidence; the F2 subject is unique and its diff quotes the stamp; the log is append-only (8913c806e +3/−0).
Copilot threads. record F1 (1419…/ISSUE.md:30): NO_ACTION, reply r4149501237, value kept and valid, resolved. record F2 (evidence L4): fixed by docs(issues): [#2393] quote the evidence timestamp, landed, resolved. Every last-updated-utc in the PR is quoted.
| Finding | Severity | Live on develop |
Recomputation |
|---|---|---|---|
| loop F3 | Minor | yes | Log entry stamped 2026-09-30 15:59 UTC records the fix, push and both replies; 2e68daec8 was authored 21:22:11Z and the replies posted 21:25:31Z/21:25:33Z |
| loop F4 | Minor | yes | Evidence V1 records single-run commands for 200, 100 and 1+50 repeated runs; the recorded commands cannot reproduce the recorded counts |
| loop F5 | Nit | yes | Four subissue specs keep last-updated-utc: "2026-09-30 14:58" after 3ae3ab728 (15:22:17Z) changed related-pr from null to 2397 |
Checked, no finding: commit subjects (6/6 conventional), author ≤ committer and ordered; AI-attribution trailer (word-boundary grep): 0 hits over 6 commits; banned token: 0 in 8 changed files; branch: "2392-test-isolation-spec" equals the PR head ref per create-issue Step 6; the evidence artifact 4d64d3c34 differs from 9d840f55d only in docs and from the head in no tested file; the filter test(/…registration_fails$/) selects exactly the two tests at server.rs:835,863; record F1's cargo run line and the outputs 1147 passed/49 passed need cargo (unverifiable here).
Checks
- Loop gate on the head worktree: pre-commit-profile gate (
pre-commit.sh --format=json) passed, exit 0, 84 s;clippy-allow-reasons --base-ref ec80aa0fbexit 0; worktree unchanged after the run. - CI is not graded post-merge.
| - 2026-09-30 15:59 UTC - Started audit for Copilot review 5368546961 (submitted 15:39 UTC, Lite | ||
| effort after an agentic-review timeout): two inline threads, no reviewer finding IDs, and a | ||
| review body with no independently actionable assertion. Normalized as F1 and F2. | ||
| - 2026-09-30 15:59 UTC - Fixed F2 in `docs(issues): [#2393] quote the evidence timestamp`, pushed |
There was a problem hiding this comment.
[Minor][F3] Processing Log entry is dated 5 h 23 min before the commit and replies it records
loop F3 (round 1, post-merge). This entry is stamped 2026-09-30 15:59 UTC and says the author fixed F2 in docs(issues): [#2393] quote the evidence timestamp, pushed it, and replied on both threads. The bytes date those events later: commit 2e68daec8, which carries that subject, has author and committer time 2026-09-30T22:22:11+01:00 (21:22:11Z). The two replies, r4149501237 and r4149501421, were created at 2026-09-30T21:25:31Z and 21:25:33Z (created_at in the REST comments; createdAt in GraphQL). An audit log entry cannot precede the push and replies it reports.
validate-audit-record.py exits 0 on this record because it checks only that the log is in chronological order. process-pr-review (SKILL.md:229-231) leaves stamp-versus-event checks to the reader. Merged-tree-wrong test: met (a log entry dated before its event). Live on develop 86392041d: yes; the file is unchanged since the head.
| cargo nextest run -p torrust-tracker-axum-http-server --no-run | ||
| ``` | ||
|
|
||
| 2. Ran the two duplicate-registration tests 200 times: |
There was a problem hiding this comment.
[Minor][F4] V1 records single-run commands for the 200, 100 and 1+50 repeated runs it reports
loop F4 (round 1, post-merge). Steps 2–4 state repetition counts ("200 times", "100 times", "once, then 50 more times"), but each recorded command is a single cargo nextest run invocation. No loop, stress option or retry count appears, and nextest runs each selected test once per invocation. The Observed Result gives totals for those repetitions ("200 passed", "100 passed", "full-suite runs 2-51: 49 passed, 1 failed"), and the recorded commands, run as written, cannot produce them.
docs/templates/ISSUE.md:180-183 asks for the "Exact command or interaction actually performed", and create-issue/SKILL.md:135 asks for "actual commands". #2393's AC5 ("The original full parallel reproduction command passes repeatedly") and M4 ("Repeat the original full-suite command") both depend on this record, so the like-for-like recheck has no recorded command for the repetition it must reproduce.
What does hold at head: the package name, the test filter (it selects exactly server.rs:835 and :863) and the test names are all real. The artifact 4d64d3c34 differs from the head in no tested file. Merged-tree-wrong test: met (an evidence line that does not reproduce). Live on develop 86392041d: yes.
| spec-path: docs/issues/open/2393-2392-test-port-allocation-races/ISSUE.md | ||
| branch: "2392-test-isolation-spec" | ||
| related-pr: 2397 | ||
| last-updated-utc: "2026-09-30 14:58" |
There was a problem hiding this comment.
[Nit][F5] last-updated-utc predates the related-pr edit in all four subissue specs
loop F5 (round 1, post-merge). cdf7aa899 (authored 15:17:46Z) committed this spec with related-pr: null. 3ae3ab728 (docs(issues): record spec-only PR #2397 in test isolation subissue specs, authored 15:22:17Z) changed it to related-pr: 2397 here (line 11) and in the #2394, #2395 and #2396 specs. All four kept last-updated-utc: "2026-09-30 14:58" and added no progress-log entry, so each file's stated last-update time precedes its last update by at least 19 minutes.
No repository rule explicitly requires bumping the field: frontmatter-validator/README.md:73 fixes only its format, and create-issue/SKILL.md:118 only requires it to be present. The field's own name is the claim. Merged-tree-wrong test: met (a claim false at the head it ships in). Live on develop 86392041d: yes.
…cible and the CI total consistent Review findings F20 and F21 of PR torrust#2690 (review 5713751044, submitted 2026-10-30 14:28:48 UTC), still unprocessed when that pull request merged at 16:24:59 UTC. - The merge list used `--since=2026-10-01`, which takes the time of day of the run: replayed late in the day it omits torrust#2397, torrust#2400 and torrust#2401, not two merges as the evidence said. The commands now use `--since=2026-10-01T00:00:00Z`, which reproduces exactly the 189 rows of `evidence/ci-to-merge.tsv`. - The OS Compatibility row is 133.7 runner-hours (24.765 minutes mean x 324 / 60), not 133.8, and the total is stated as the unrounded sum rounded once (567.1); the comparison row said 567.0. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…d correct the post-merge review findings of PR 2690 64c1a24 docs(pr-reviews): [#2547] record the third review round of PR 2693 (josecelano-bot) 014c0f4 docs(pr-reviews): [#2547] attribute the F5 re-check reply to its owning review (josecelano-bot) 6004de7 docs(pr-reviews): [#2547] record the second review round of PR 2693 (josecelano-bot) 1d813fe docs(pr-reviews): [#2547] keep the pending resolution references parseable (josecelano-bot) 0233869 docs(pr-reviews): [#2547] record the resolution of the PR 2693 review threads (josecelano-bot) bb5a788 docs(pr-reviews): [#2547] record the review of PR 2693 (josecelano-bot) 892ab8d docs(pr-reviews): [#2547] word the reply-url resolution references accurately (josecelano-bot) 390dbb1 docs(pr-reviews): [#2547] use the reply urls as the pending resolution references (josecelano-bot) 6f30c5f docs(pr-reviews): [#2547] record F20 and F21 as re-raises of F3 (josecelano-bot) 8eaaf8c docs(pr-reviews): [#2547] retain the reviewer-provided ids of F20 to F22 (josecelano-bot) 09b93bc docs(issues): [#2547] refresh the update date of the #2507 spec after the path repair (josecelano-bot) e396d7f docs(pr-reviews): [#2547] record the post-merge findings F20 to F22 of PR 2690 (josecelano-bot) f499663 chore(issues): archive closed issue #2547 spec to docs/issues/closed (josecelano-bot) a4a65f3 docs(issues): [#2547] make the merge-list construction reproducible and the CI total consistent (josecelano-bot) Pull request description: ## Summary Follow-up to the merged pull request #2690 (the post-change measurement of issue #2547, which closed on that merge). It carries the three non-blocking findings of da2ce7's approving review 5713751044 that were still unprocessed when #2690 merged, and archives the spec of the closed issue. The maintainer approved this post-merge follow-up in #2690 (comment). - **F20** (inline thread on `post-change-evidence.md`): `git log --since=2026-10-01` takes the time of day at which it runs, so the merge list omitted #2397, #2400 and #2401, not two merges as the text said. The commands use `--since=2026-10-01T00:00:00Z`, which lists all three and reproduces exactly the 189 rows of `evidence/ci-to-merge.tsv`. Commit `docs(issues): [#2547] make the merge-list construction reproducible and the CI total consistent`. - **F21**: the OS Compatibility row is 133.7 runner-hours (not 133.8), and the total is stated as the unrounded sum (567.05) rounded once to 567.1; the comparison row said 567.0. Same commit. No conclusion of the evidence changes. - **F22**: the audit's 13:53 "Started audit" entry placed the 11 replies before the audit began; they ran 13:54:12 to 13:54:34 UTC. An append-only correction is added to `docs/pr-reviews/pr-2690-review/PR-REVIEW.md`; the original entry is kept. - The spec of issue #2547 moves to `docs/issues/closed/` (`status: done`), with the live references to the old path updated (commit `chore(issues): archive closed issue #2547 spec to docs/issues/closed`). ## Files touched - `docs/issues/closed/2547-measure-effect-of-optional-rebases/` (moved from `docs/issues/open/`; evidence and retrospective corrected) - `docs/issues/closed/2507-stop-requiring-pull-request-rebases/ISSUE.md` and `docs/pr-reviews/pr-2550-review/PR-REVIEW.md` (path in `related-artifacts`) - `docs/pr-reviews/pr-2690-review/PR-REVIEW.md` (rows F20 to F22 and the Processing Log) Documentation only; no code changes. `linter all` passes on every commit. Review of this pull request (da2ce7, reviews 5715892693 and 5716380696): seven findings, F1 to F7 (F7 continues F5), fixed in six signed commits on top of the three above, plus the commits that record the audit (the audit of this pull request is `docs/pr-reviews/pr-2693-review/PR-REVIEW.md`). F2 required correcting the body of the first commit (`docs(issues): [#2547] make the merge-list construction reproducible and the CI total consistent`), which wrongly said the findings were raised after the merge; **the history was rewritten once** to reword that body (`git rebase -i`, pushed with `--force-with-lease`), keeping every commit, and the final tree is identical to the one before the rewrite. ## Related Related to #2547 and #2690. The three threads of review 5713751044 stay open until this pull request merges. 🤖 Generated with [Claude Code](https://claude.com/claude-code) ACKs for top commit: josecelano: ACK 64c1a24 Tree-SHA512: 9f4ed2d4bb16499039b77c85ef9d9059dbaa1b275e883176292e53887f4cb18b6f0d6299f3d06efd0726625f997551df7bbe9d364ec3dfee8b95d24fc3225568


Summary
Spec-only PR for the new Test Isolation EPIC. It adds the EPIC and four subissue specifications, and links the existing #1419 to the EPIC. No code, test, or workflow changes.
The EPIC's goal is that every test owns the resources it uses (ports, container images and names, filesystem paths, process-global state), so results depend only on the code under test. The driver is a robust suite without flaky tests; faster CI is a side benefit. EPIC #1840 is related, not the parent.
Changes
docs/issues/open/2392-test-isolation/EPIC.md: scope, isolation rules, delivery order, and the relationship to EPIC EPIC: Improve PR Workflow Performance #1840.docs/issues/open/2393-2392-test-port-allocation-races/: bug spec plusmanual-verification-evidence.mdwith the local reproduction (51 full nextest runs, 2AddrInUsefailures in two tests; 0 failures in 300 narrower runs).docs/issues/open/2394-2392-audit-shared-test-resources/ISSUE.md: inventory of shared test resources by class, with a disposition per finding.docs/issues/open/2395-2392-e2e-runner-dynamic-host-ports/ISSUE.md: let Docker assign the E2E runner's host ports and discover them.docs/issues/open/2396-2392-e2e-unique-tracker-image-tag/ISSUE.md: per-run tracker image tag incontainer.yamlandtesting.yaml, with always-run cleanup.docs/issues/open/1419-allow-multiple-integration-tests-at-main-app-level/ISSUE.md: records the parent EPIC. Editing an open spec requires v1 frontmatter, so it is migrated in a separate commit (statusopenbecameblocked, because the remaining AC8a waits on Overhaul: Tracker Shutdown #1488).GitHub: #2392 was created with sub-issues #2393, #2394, #2395, #2396, and #1419.
Validation
linter all, hadolint, doc tests).frontmatter-validatorpasses on all six changed specs after rebasing onto the latestdevelop.Issues
Related to #2392
Related to #2393
Related to #2394
Related to #2395
Related to #2396
Related to #1419