You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
refactor(http-protocol): merge announce DTO layer into layered module
Moved deserialization types from `announce_deserialization.rs` into `announce/deserialization.rs`
- Renamed: `Announce` → `DeserializedNormal`, `Compact` → `DeserializedCompactParsed`
- Added `peers6` field to `DeserializedCompact` (IPv6 support per BEP 7)
- Replaced `CompactPeer` (IPv4-only struct) with shared `encoding::CompactPeer` enum (IPv4+V6)
- Added `CompactPeer::new_from_bytes` supporting both 6-byte IPv4 and 18-byte IPv6 formats
- Deleted `announce_deserialization.rs`
- Updated all 8 import sites across 6 files
- Spec progress: T11 marked DONE
- All linters and tests pass
| T1 | DONE | Survey duplicate types and decide merge strategy | Catalog exact types to move; identify which location has the "best" version |
217
-
| T2 | DONE | Add client-side types to `http-protocol`| Move query builders, response deserialization structs, and shared helpers |
218
-
| T3 | DONE | Add `http-protocol` dependency to `tracker-client`| Update `Cargo.toml`, verify dependency tree |
219
-
| T4 | DONE | Replace duplicate types in `tracker-client`| Delete local copies, update imports to `http-protocol`|
220
-
| T5 | DONE | Replace duplicate types in `axum-http-server` tests | Delete local copies, update imports to `http-protocol`|
221
-
| T6 | DONE | Run full verification (Iteration 1) |`linter all`, `cargo test --workspace`, pre-commit, pre-push |
222
-
|||**Request-side unification (DD6)**||
223
-
| T7 | DONE | Merge `announce_builder::Query` into `Announce`| See [analysis](./analysis-announce-query-vs-announce.md). Added `peer_addr`, `Display`, `AnnounceBuilder`; removed `announce_builder` module |
224
-
| T8 | DONE | Update all call sites for unified `Announce`|~54 call sites updated across 7 files: contract.rs, client.rs, CLI apps, stats test |
225
-
| T9 | DONE | Run full verification after announce request merge |`linter all`, `cargo test --workspace`, `cargo test --doc --workspace` — all passed |
226
-
|||**Response-side restructuring (DD7 + DD8)**||
227
-
| T10 | DONE | Restructure announce responses into layered module | Created `announce/{data,encoding}.rs` with `mod.rs` re-exports. Deleted old `announce.rs`. No call sites needed updating (backward compatible) |
| T1 | DONE | Survey duplicate types and decide merge strategy | Catalog exact types to move; identify which location has the "best" version |
217
+
| T2 | DONE | Add client-side types to `http-protocol`| Move query builders, response deserialization structs, and shared helpers |
218
+
| T3 | DONE | Add `http-protocol` dependency to `tracker-client`| Update `Cargo.toml`, verify dependency tree |
219
+
| T4 | DONE | Replace duplicate types in `tracker-client`| Delete local copies, update imports to `http-protocol`|
220
+
| T5 | DONE | Replace duplicate types in `axum-http-server` tests | Delete local copies, update imports to `http-protocol`|
221
+
| T6 | DONE | Run full verification (Iteration 1) |`linter all`, `cargo test --workspace`, pre-commit, pre-push |
222
+
|||**Request-side unification (DD6)**||
223
+
| T7 | DONE | Merge `announce_builder::Query` into `Announce`| See [analysis](./analysis-announce-query-vs-announce.md). Added `peer_addr`, `Display`, `AnnounceBuilder`; removed `announce_builder` module |
224
+
| T8 | DONE | Update all call sites for unified `Announce`|~54 call sites updated across 7 files: contract.rs, client.rs, CLI apps, stats test |
225
+
| T9 | DONE | Run full verification after announce request merge |`linter all`, `cargo test --workspace`, `cargo test --doc --workspace` — all passed |
226
+
|||**Response-side restructuring (DD7 + DD8)**||
227
+
| T10 | DONE | Restructure announce responses into layered module | Created `announce/{data,encoding}.rs` with `mod.rs` re-exports. Deleted old `announce.rs`. No call sites needed updating (backward compatible) |
228
+
| T11 |DONE| Partial merge of announce DTO layer |Moved deserialization types into `announce/deserialization.rs`. Renamed `Announce` → `DeserializedNormal`, `Compact` → `DeserializedCompactParsed`. Added `peers6` to `DeserializedCompact`. Replaced `CompactPeer`(IPv4-only struct) with shared `encoding::CompactPeer` enum. Deleted `announce_deserialization.rs`. Updated 8 import sites.|
229
+
| T12 | TODO | Restructure scrape responses into layered module | Same pattern: `scrape/{data,encoding,deserialization}.rs`|
230
+
| T13 | TODO | Partial merge of scrape DTO layer | Same pattern as announce |
231
+
| T14 | TODO | Update all call sites for restructured response types | Update imports in tracker-client, axum-http-server tests, CLI apps |
232
+
| T15 | TODO | Run full verification after response restructure |`linter all`, `cargo test --workspace`, pre-commit, pre-push |
233
+
|||**Finalization**||
234
+
| T16 | TODO | Replace duplicate HTTP test client (DD9) | Remove `packages/axum-http-server/tests/server/client.rs`; update tests to use `tracker-client` package |
235
+
| T17 | TODO | Create `use-tracker-client` skill | New skill in `.github/skills/usage/use-tracker-client/` with learnings from manual verification |
236
236
237
237
## Progress Tracking
238
238
@@ -259,6 +259,7 @@ Status values: `TODO`, `IN_PROGRESS`, `BLOCKED`, `DONE`.
259
259
- 2026-07-13 16:00 UTC - Copilot - Response-side analysis: decided to restructure into layered modules (DD7) and partial DTO merge (DD8). New tasks T10-T15 added.
260
260
- 2026-07-14 10:00 UTC - Copilot - Implementation (T7-T9) completed: merged `announce_builder::Query` into `Announce`, updated all call sites, all verifications passed.
261
261
- 2026-07-14 14:00 UTC - Copilot - Implementation (T10) completed: restructured announce responses into `announce/{data,encoding}.rs` layered module.
262
+
- 2026-07-14 15:00 UTC - Copilot - Implementation (T11) completed: partial merge of announce DTO layer into `announce/deserialization.rs`.
0 commit comments