feat(tracker-client): add UDP response format option and testing skill links#1756
Conversation
There was a problem hiding this comment.
Pull request overview
This PR implements issue #1563 by adding a --format option to the UDP tracker client so responses can be printed as either compact JSON (default) or pretty JSON, and adds a new developer skill document for choosing public trackers when manually testing tracker clients.
Changes:
- Added
--format {compact|pretty}to UDPannounceandscrapecommands and threaded it through to JSON serialization. - Made UDP JSON serialization format-aware and added unit tests covering compact vs pretty serialization.
- Added a new “public trackers for testing” skill doc and linked it from the HTTP/UDP client module docs via
skill-linkmarkers.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| docs/issues/open/1563-udp-tracker-client-add-option-show-response-pretty-json.md | Updates spec checklist/progress and adds manual verification evidence for the new format option. |
| console/tracker-client/src/console/clients/udp/responses/json.rs | Adds compact vs pretty JSON serialization support and unit tests. |
| console/tracker-client/src/console/clients/udp/app.rs | Adds --format CLI option, passes it to serializer, updates examples, and adds a skill-link marker. |
| console/tracker-client/src/console/clients/http/app.rs | Adds a skill-link marker. |
| .github/skills/dev/testing/public-trackers-for-testing/SKILL.md | New skill doc listing public endpoints and copy/paste commands for manual testing. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #1756 +/- ##
===========================================
+ Coverage 79.38% 79.40% +0.02%
===========================================
Files 368 368
Lines 27140 27160 +20
Branches 27140 27160 +20
===========================================
+ Hits 21544 21567 +23
+ Misses 5315 5310 -5
- Partials 281 283 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
ACK dc200b8 |
Summary
Implements issue #1563 for UDP tracker client response formatting and adds a new developer skill for public tracker testing guidance.
Changes included
--formatoption to UDP tracker clientannounceandscrapecommands.compact(default)pretty.github/skills/dev/testing/public-trackers-for-testing/SKILL.md.skill-link: public-trackers-for-testingmarkers in:console/tracker-client/src/console/clients/udp/app.rsconsole/tracker-client/src/console/clients/http/app.rsVerification
cargo check -p torrust-tracker-clientcargo test -p torrust-tracker-clientcargo test -p torrust-tracker-client console::clients::udp::responses::json::testslinter allcargo macheteIssue