Repository navigation
docs(issues): add spec for keeping the request kind in the UDP error-response event - #2346
Conversation
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
Spec-only PR documenting a UDP server event-contract bug where Processor::send_response drops a known request kind when publishing Event::UdpResponseSent for error responses, plus updates to the team’s bug-fix workflow to require clearer specs and pre-review reproduction evidence.
Changes:
- Added an issue specification describing the bug, impact, scope, regression-test strategy, and acceptance criteria.
- Added manual verification evidence capturing pre-fix reproduction steps and observed event output.
- Updated the
fix-bugskill workflow to require plain-language explanations, classified reproduction evidence, and explicit red-before-fix regression tasks.
| File | Description |
|---|---|
| docs/issues/open/2345-keep-request-kind-in-udp-error-response-event/ISSUE.md | New bug spec documenting the event-contract mismatch and a concrete regression plan. |
| docs/issues/open/2345-keep-request-kind-in-udp-error-response-event/manual-verification-evidence.md | New evidence log capturing how the internal-only bug was observed via a temporary test. |
| .github/skills/dev/debugging/fix-bug/SKILL.md | Workflow update to standardize spec requirements and reproduction/evidence expectations. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
da2ce7
left a comment
There was a problem hiding this comment.
Reviewed at a75ef112987fd05eb1c802f831ddbf141debe3ff (round 1). Recomputed from the bytes at this head.
Two commits on dee5ec21 (docs(issues): add issue specification for #2345, docs(skills): require classified reproduction and self-check in bug specs) touch three files, +481/−1 in the three-dot diff: the #2345 bug spec, its evidence file, and fix-bug v1.1. The spec plans a one-line fix so the Response::Error arm of Processor::send_response keeps the known request kind in UdpResponseSent. The skill amendment turns the lessons from drafting it into required spec content and a pre-review self-check.
What I verified
- The bug holds at head.
processor.rs:122hard-codesError { opt_req_kind: None }. For a parsed request whose handler fails,handle_packetreturns(response, Some(req_kind))(handlers/mod.rs:102-122; scrape'smap_erratscrape.rs:97carriesUdpRequestKind::Scrape). That contradicts the contract atevent.rs:106-110.27e2db4bintroduced the arm, under exactly the quoted subject, andresponse_sent.rs:50ignores the field. - V1 matches the source. The test is at
tests/server/contract.rs:250underreceiving_an_announce_request(targettests/integration.rs). Its WARN line comes fromhandlers/error.rs:103, and the cookie bound in the recorded line dates the run to 10:37 UTC. - V2 matches the source. Every helper, import and shape it uses resolves from the
testsmodule. The observed order matches the strict-mode publish sites:scrape.rs:42→error.rs:147→processor.rs:152. - The plan matches the skill. It follows the Required Sequence (
fix-bug/SKILL.md:25-50): B1 records the reproduction, B2 goes red, B3 fixes, B4 is green plus recheck. The six self-check boxes are met in substance; F2, F3 and F7 are about wording. - The spec matches the template and its siblings. Frontmatter and section order match
docs/templates/ISSUE.mdand the #2342 and #2314 siblings. - The new rules live in one place.
create-issuedefers bug-only content tofix-bug(create-issue/SKILL.md:29-33,:172-177).
Findings
Eight inline findings, none blocking (6 Nit, 2 Suggestion): F1 V1's request count; F2 the reproduction-outcome labels; F3 the M1/M2 status values; F4 status: open; F5 how the worked example is linked in; F6 the dropped agent-review-reports.md lines; F7 the scope of self-check item 5; F8 a single deadline for the event loop.
Copilot
- Unquoted
last-updated-utcin the evidence file: I don't think this needs a change. The evidence template ships the field unquoted (docs/templates/MANUAL-VERIFICATION-EVIDENCE.md:4), and 16 of 22 evidence files ondevelopdo the same. The strict frontmatter profile only checksissue/epicdocuments.2026-09-26 10:52has no seconds, so YAML does not read it as a timestamp. req kin: I don't think this needs a change. It is the verbatim subject of27e2db4b, cited in backticks right after the commit id. Correcting it would break the citation.
Checked, no finding
- The three-dot diff has 3 files, no Rust and no
project-words.txtchange.packages/is identical todevelop. - The branch ends in
-spec. The title has no[#2345]and the body saysRelated to #2345, ascreate-issuerequires for a spec-only PR. - Both commits are Conventional with bodies that say why, have no attribution trailer, and have author and committer times in order.
merge-treeagainstdevelopis clean, and there is no banned token. - The ADR path exists. The other events for the request carry the kind (
scrape.rs:49,error.rs:150). - The fixture the strategy names already exists:
setup_processor_with_event_receiver,receive_eventandEVENT_PUBLICATION_TIMEOUT. - AC1/AC2 match the two planned tests. Issue #2345 was created at 11:01:19Z, matching the 11:01 progress-log entry.
- The
fix-bugdescription is still accurate. The version bump is additive, and there are noskill-link: fix-bugmarkers to sync. - The #2283 pause note cannot be verified from the tree.
Orchestrator's server checks (not part of the lane's recomputation). Gate of record on the detached worktree at this head (pre-commit profile with linter all, plus clippy-allow-reasons against 0f1dcd287): passed in 41 s. V1 rerun: the strict-mode contract test passes as recorded. V2 rerun: the temporary test from the evidence file, inserted verbatim at the end of processor.rs's tests module, compiles and prints UdpRequestAccepted { kind: Scrape }, UdpError { kind: Some(Scrape), .. }, then UdpResponseSent { kind: Error { opt_req_kind: None }, .. } — the reproduction holds at this head. CI at this head: Docs Lint success (docs-only change).
|
ACK a75ef11 — bug spec for #2345: the Error arm of send_response drops the kind handle_packet returns for a parsed request, against the event.rs contract, reproduced by a recorded temporary event-bus test whose helpers and publish order match the source; plan follows fix-bug's Required Sequence with a red-first regression test; fix-bug v1.1 adds the reproduction classification and self-check the spec meets in substance (eight non-blocking nits and suggestions) |
a75ef11 to
c42b186
Compare
Audit all ten review findings on the torrust#2345 spec-only PR: eight fixed in their own commits and two Copilot findings declined with verified reasons; every thread replied to and resolved.
da2ce7
left a comment
There was a problem hiding this comment.
Reviewed at 6f9630d44555856dd7c4fdbd617a27ec75722908 (round 3). Recomputed from the bytes at this head.
Since round 1. The branch was rebased from dee5ec21 onto develop 0f1dcd28. Both round-1 commits are patch-identical under git range-diff, and develop moved only in docs (#2343). Eight commits then address F1–F8, one each: +37/−23 over the three spec files, with every hunk explained by a reply. The last push adds docs(pr-reviews): record PR #2346 review audit, which touches only the new docs/pr-reviews/pr-2346-review/PR-REVIEW.md. The three-dot diff is 4 files, +767/−2. packages/ and project-words.txt are untouched, and the evidence file's temporary V2 test is byte-identical to round 1.
Round-1 threads (10, all now resolved).
- Copilot 1: no change, right because the evidence template ships the field unquoted (
MANUAL-VERIFICATION-EVIDENCE.md:4) and the strict profile applies only toissue/epicwithschema-version(profile.rs:108-113,:124-126).2026-09-26 10:52has no seconds, so it is not a YAML 1.1 timestamp, and the YAML 1.2 core schema has no timestamp tag. - Copilot 2: no change, right because it is the verbatim subject of
27e2db4b(ondevelop), quoted in backticks after the id. - F1: closed. There are eleven error-answered announces (
contract.rs:272-285); the twelfth is discarded as banned beforeprocess_requestis spawned (launcher.rs:182,:214). - F2: closed. The skill's bold labels are used (evidence
:45,:77). - F3: closed. M1/M2 are
DONEand M3/M4 areTODO;Post-Fix Recheckexists, and AC4 names M3/M4. - F4: closed. The status is
planned(profile.rs:206). - F5: closed.
"issue #2345"uses the same form as #2226, with a Skill Links entry and "either issue". - F6: closed. The checkpoint is template
:146verbatim, and the bullet matches #2233/#2295/#2308. - F7: closed, as suggested.
- F8: closed. There is one
Instantdeadline withtimeout_at(write-unit-test/SKILL.md:158), and the plan says whyreceive_eventis not enough.
Each fix is the commit its reply names: the subjects match exactly, and git blame agrees. The fix-bug amendment still meets its own six-box self-check at this head.
Audit record. PR-REVIEW.md instantiates docs/templates/PR-REVIEW-TEMPLATE.md. It has the same six sections, with Ownership, Status Values and Completion Rules verbatim and the detail fields in roster order. There are 10 rows, each with a matching detail entry:
- F1–F8 (review 5325901139) are
FIXED/RESOLVED, with severities matching the source brackets. - F9/F10 (review 5325777400) are
NO_ACTION/SUPERSEDED, with(inferred)severities as the template allows. Their replies use the skill'sSuperseded by <FindingId>: <reason>.form.
Reviewer finding ID is N/A throughout, which is correct because no reviewer ID was reassigned. Every Source/Reply URL pair matches the captured comments. Every recorded current-tree check reproduces at this head, except the PyYAML run, which I replaced with the YAML 1.1 timestamp regex; it gives the same result. All 15 log stamps are in order and not later than the audit commit (13:10:57Z), and each "authored" stamp is its commit's author minute. validate-audit-record.py --pr-number 2346 --comments-file <capture> --base 0f1dcd28 exits 0 ({"status": "ok", "rows": 10, "log_entries": 15, "failures": 0}).
Findings: none.
Checked, no finding
- There are 11 Conventional subjects. The audit commit has a body, though AGENTS.md sets no body rule. There is no attribution trailer, and author and committer times are in order.
merge-treeagainstdevelopis clean. Only the audit record is new since round 2, and there is no banned token.- The Processing Log shows the validator run (13:08) after the replies (13:06), while
process-pr-review/SKILL.md:198-199asks for it before replying. Every reply claim holds at this head, so there is nothing to change. ISSUE.md:83is 104 characters, but MD013 is off.- The PR description still calls the skill change one "separate
docs(skills)commit"; there are now three. Its content is still accurate.
Orchestrator's server checks. Gate of record at 6f9630d44 on the current develop base 0f1dcd287 (pre-commit profile + clippy-allow-reasons, nightly): passed, 44 s wall, ALLOW_RC 0, DIFF_CHECK_OK (round-2 head c42b186ee: 71 s, same result). This head adds only the audit record, so no crate build was recomputed; packages/ is untouched since round 1 and the V1/V2 reproduction figures reported there stand. Round-2 lane wall 730 s, round-3 addendum 303 s. CI at this head at posting: Docs Lint success (the only check run this docs-only change triggers).
|
ACK 6f9630d — bug spec for #2345 at the re-pushed head: round-1 threads closed (announce count, outcome labels, M1–M4 split, planned status, restored checkpoint, one-deadline rule, #2345 link-back, DONE-scoped self-check), both Copilot no-change replies upheld, and all ten recorded in the PR #2346 audit (validator exit 0); reproduction and plan unchanged on the merits |
Specify the UDP error-response event bug where Processor::send_response drops the known request kind for parsed requests, with reproduction evidence (trigger-only tracker run and event-bus observation of Error { opt_req_kind: None }).
…pecs Extend fix-bug issue-spec requirements with lessons from torrust#2345: a plain-language bug explanation, reproduction attempted before review and classified as reproduced, trigger-only, or infeasible, temporary tests as reproduction for internal outcomes, an explicit red-before-fix regression task, and a pre-review self-check.
…roduction The strict-mode contract sends eleven announces answered with error responses, then a twelfth that is banned before handling (review-finding:pr-2346-f1).
…ction outcomes Use the fix-bug v1.1 labels verbatim: V1 is Trigger only and V2 is Reproduced (review-finding:pr-2346-f2).
…post-fix rows Each row now carries one listed status: M1 and M2 record the pre-fix runs as DONE, M3 and M4 are the planned post-fix rechecks (review-finding:pr-2346-f3).
…ontmatter open is not a schema-version 1 IssueStatus; planned means the approved spec is ready to start (review-finding:pr-2346-f4).
Restore the ISSUE template's agent-review-reports.md checkpoint and completion-review bullet that the spec had dropped (review-finding:pr-2346-f6).
… deadline EVENT_PUBLICATION_TIMEOUT is a per-receive Duration; require one tokio Instant deadline before the receive-until-UdpResponseSent loop with timeout_at, as write-unit-test asks (review-finding:pr-2346-f8).
Name both worked-example issues in the scope sentence and add issue torrust#2345 to the related artifacts and Skill Links so its reference is re-checked when its evidence moves (review-finding:pr-2346-f5).
…rows Planned post-fix rows can only describe an intended procedure at review time; require only DONE rows to describe what was actually run (review-finding:pr-2346-f7).
Audit all ten review findings on the torrust#2345 spec-only PR: eight fixed in their own commits and two Copilot findings declined with verified reasons; every thread replied to and resolved.
6f9630d to
02878fd
Compare
|
ACK 02878fd |
1268bef docs(pr-reviews): record PR #2353 thread resolution (Jose Celano) 3bbb970 docs(pr-reviews): add PR #2353 review audit (Jose Celano) b010702 docs(pr-reviews): close PR #2339 audit after PR #2344 merge (Jose Celano) Pull request description: ## Summary Closes the PR #2339 audit after its post-merge follow-up, PR #2344, merged into `develop` at `fcde51db`. This follows the PR #2276 precedent, which closed the PR #2269 audit after PR #2271 merged. - F1-F3 in `docs/pr-reviews/pr-2339-review/PR-REVIEW.md` move from `FOLLOW_UP`/`OPEN` to `FIXED`/`RESOLVED`. Their resolution references are the merged fix commits, `test(dev-tools): pin review-thread query fields and explicit nulls` (F1, F2) and `docs(issues): record the exact #2333 evidence commands` (F3). - Each `Reply URL` is now the final reply on its thread, which cites the merge. The earlier follow-up replies remain on the threads. - A Processing Log entry records the merge, the re-derivation of each fix at `develop`, and the resolution. GitHub-side actions already taken, as the approval record allows (<#2339 (comment)>): each of the three PR #2339 threads received a final reply citing `fcde51db` and was resolved. GraphQL shows 3 threads, 0 unresolved. ## Files touched - `docs/pr-reviews/pr-2339-review/PR-REVIEW.md` - `docs/pr-reviews/pr-2353-review/PR-REVIEW.md`: audit for this PR's review round 1. ## Review Round 1 Copilot review 5329114076 raised one concern on three lines: use SHA permalinks instead of commit subjects in the `FIXED` resolution references. Recorded as F1, with F2 and F3 as re-raises, all `NO_ACTION`/`SUPERSEDED`. `process-pr-review` requires unique commit subjects and forbids branch SHAs, the EPIC #2278 Decision Record keeps that form, each cited subject matches exactly one commit, and each row already links PR #2344. Replied with the prescribed `Superseded by F1:` form and resolved. - `docs(pr-reviews): add PR #2353 review audit` - `docs(pr-reviews): record PR #2353 thread resolution` Rebased onto `develop` `6a7f1db5` (after PR #2350) before processing, and again onto `41e7938c` (after PR #2346) before merge; both rebases were clean. ## Validation - `validate-audit-record.py --pr-number 2339 --base a20e8f3` exits `0` (3 rows, 3 log entries). The base is the PR #2339 merge, so the merged fix commits are in range; the default base `develop` already contains them. - At `develop`, `cargo test --package github-review-threads` passes 15 unit and 7 CLI tests. - The pre-commit hook (including `linter all`) and the pre-push hook passed. Related to #2333 Related to #2278 ACKs for top commit: josecelano: ACK 1268bef Tree-SHA512: b175303681549518fdf713273ba82e564ac6ad56fa415fc131b8fa4b5fdebce671976ce5e1480e5bbc69bb9be8827c413c7d5d08def2f17fb623dc5a81d7523d
Record the merged spec-only PR torrust#2346, switch the spec to the implementation branch, and mark it in progress.
|
Post-merge note on the 2026-09-27T08:24Z re-review request (head The merged head is the round-3 head |
…ssues/closed 87ae27a docs(issues): link the #2345 archival review report (Jose Celano) 2108743 chore(issues): archive closed issue #2345 spec to docs/issues/closed (Jose Celano) Pull request description: Archives the completed specification for #2345 from `docs/issues/open/` to `docs/issues/closed/`. - Verified #2345 is `CLOSED` on GitHub after PR #2354 merged. - Preserved the folder and its verification and review artifacts with Git renames. - Updated the primary spec to `status: done`, repaired issue-local frontmatter paths, recorded the archival action, and completed the closure checkpoints. - Retained the one historical #2346 review-audit reference to the former open path. Validation: `linter all`, the pre-commit gate, and the pre-push suite (nightly checks, nightly documentation build, full stable test suite) passed. ACKs for top commit: josecelano: ACK 87ae27a Tree-SHA512: 4aaca53ea54b7f4f6e637df9933ec362e238719fffc7edbb74317238efe68acd1cb12c7704387c1449230f2bf2b40398938c27425cefb0d5b47e3a88c1ee8392
|
Post-merge note: this pull request requested a review from this account and was closed without one at its final head. A post-merge review will not be done: This account approved the final head of this pull request; the open review request is a stale re-request. |


Summary
Spec-only PR for the UDP error-response event bug:
Processor::send_responsedrops the known request kind for parsed requests and publishesUdpResponseSent { kind: Error { opt_req_kind: None } }, contradicting the documentedUdpResponseKind::Errorcontract. Implementation follows in a separate branch after this merges.Related to #2345
Changes
docs/issues/open/2345-keep-request-kind-in-udp-error-response-event/ISSUE.md: bug specification with a plain-language explanation, reproduction summary, regression-test strategy (processor unit tests, red before the fix), implementation plan, and acceptance criteria.docs/issues/open/2345-keep-request-kind-in-udp-error-response-event/manual-verification-evidence.md: pre-fix reproduction. V1 is a trigger-only real-tracker run (the event field is not visible to clients, metrics, or logs); V2 is a temporary event-bus test, recorded verbatim and reverted, that observedError { opt_req_kind: None }for a parsed scrape..github/skills/dev/debugging/fix-bug/SKILL.md(separatedocs(skills)commit): bug specs must now include a plain-language explanation, a reproduction attempted before review and classified as reproduced, trigger-only, or infeasible, temporary tests as valid reproduction for internal outcomes, an explicit red-before-fix regression task, and a pre-review self-check. These lessons came from drafting this spec.docs/pr-reviews/pr-2346-review/PR-REVIEW.md(separatedocs(pr-reviews)commit): audit of review round 1. Eight findings (F1-F8) are fixed in their own commits across the spec, evidence, and skill; two Copilot findings (F9, F10) are declined with verified reasons. Every thread was replied to and resolved.No production or test code is changed. The temporary reproduction test was a local-only patch and is not included.
Validation
./contrib/dev-tools/git/hooks/pre-commit.shpassed (stable Rust 1.98.1, includinglinter all).developcommits or non-commit data.