CLI app for developers prototyping atproto functionality
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix Phase 4 cycle 4 review issues

- Identity tests now use cursorless healthy_labels_response to avoid HTTP stage
triggering an unconfigured-second-page request, removing [NET] noise rows from
all 12 identity snapshots.
- Replace fully-qualified paths in pipeline.rs with imported module aliases.
- Document HttpFacts as consumed by Phase 6 Crypto stage.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>

+9 -9
+1 -1
src/commands/test/labeler/http.rs
··· 422 422 true 423 423 }; 424 424 425 - // Build and return facts. 425 + // Facts consumed by Phase 6 Crypto stage. 426 426 let facts = HttpFacts { 427 427 first_page: first_page_labels, 428 428 first_page_raw_bytes,
+3 -3
src/commands/test/labeler/pipeline.rs
··· 8 8 use url::Url; 9 9 10 10 use crate::commands::test::labeler::http::{self, RealHttpTee}; 11 + use crate::commands::test::labeler::identity; 11 12 use crate::commands::test::labeler::report::{ 12 13 CheckResult, CheckStatus, LabelerReport, ReportHeader, Stage, 13 14 }; ··· 48 49 /// DNS resolver for handle lookups. 49 50 pub dns: &'a dyn DnsResolver, 50 51 /// HTTP tee for the labeler endpoint (optional, defaults to RealHttpTee). 51 - pub raw_http_tee: Option<&'a dyn crate::commands::test::labeler::http::RawHttpTee>, 52 + pub raw_http_tee: Option<&'a dyn http::RawHttpTee>, 52 53 /// Shared reqwest client for both identity and HTTP stages (optional). 53 54 pub reqwest_client: Option<&'a reqwest::Client>, 54 55 /// Per-connection time budget for subscription checks. ··· 195 196 let mut report = LabelerReport::new(header); 196 197 197 198 // Run the identity stage. 198 - let identity_output = 199 - crate::commands::test::labeler::identity::run(&target, opts.http, opts.dns).await; 199 + let identity_output = identity::run(&target, opts.http, opts.dns).await; 200 200 201 201 // Populate header from facts if available. 202 202 if let Some(ref facts) = identity_output.facts {
+1 -1
tests/labeler_identity.rs
··· 114 114 115 115 /// Helper function to return a healthy labels response (non-empty with valid labels). 116 116 fn healthy_labels_response() -> Vec<u8> { 117 - include_bytes!("fixtures/labeler/http/healthy/first_page.json").to_vec() 117 + br#"{"cursor":null,"labels":[{"ver":1,"src":"did:plc:healthy","uri":"at://did:plc:healthy/app.bsky.feed.post/abc","val":"test-label","neg":false,"cts":"2026-04-13T00:00:00.000Z"}]}"#.to_vec() 118 118 } 119 119 120 120 #[tokio::test]
+2 -2
tests/snapshots/labeler_identity__did_plc_direct_happy_path.snap
··· 21 21 == HTTP == 22 22 [OK] Labeler endpoint is reachable 23 23 [OK] First page schema is valid 24 - [NET] Network error fetching second page: tcp connect: connection refused 24 + [OK] First page was complete; pagination not exercised 25 25 == Subscription == 26 26 [SKIP] Subscription stage (stub) — not yet implemented (phase 5) 27 27 == Crypto == 28 28 [SKIP] Crypto stage (stub) — not yet implemented (phase 6) 29 29 30 - Summary: 10 passed, 0 failed (spec), 1 network errors, 0 advisories, 3 skipped. Exit code: 0 30 + Summary: 11 passed, 0 failed (spec), 0 network errors, 0 advisories, 3 skipped. Exit code: 0
+2 -2
tests/snapshots/labeler_identity__healthy_plc_renders_all_ok.snap
··· 21 21 == HTTP == 22 22 [OK] Labeler endpoint is reachable 23 23 [OK] First page schema is valid 24 - [NET] Network error fetching second page: tcp connect: connection refused 24 + [OK] First page was complete; pagination not exercised 25 25 == Subscription == 26 26 [SKIP] Subscription stage (stub) — not yet implemented (phase 5) 27 27 == Crypto == 28 28 [SKIP] Crypto stage (stub) — not yet implemented (phase 6) 29 29 30 - Summary: 10 passed, 0 failed (spec), 1 network errors, 0 advisories, 3 skipped. Exit code: 0 30 + Summary: 11 passed, 0 failed (spec), 0 network errors, 0 advisories, 3 skipped. Exit code: 0