Skip to content

Commit 471f442

Browse files
author
Mateusz
committed
Refactor CBOR capture inspector into src.core.wire_capture.inspection
Move logic from scripts/inspect_cbor_capture.py into modular package (loader, metadata, correlation, filters, issues, analysis, render, export, app orchestration). Thin script keeps epilog and prepends repo root for imports. Use writeln() instead of print in src to satisfy no-print policy. Loader keeps unbounded entry count for inspection vs CaptureReader cap. Update usage_report, repro script, and tests to import from src; add unit test for header validation. Made-with: Cursor
1 parent cac357c commit 471f442

24 files changed

Lines changed: 2593 additions & 2289 deletions

dev/scripts/repro_streaming_repeat_and_dedup.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ async def _cmd_from_capture(args: argparse.Namespace) -> int:
117117

118118
# Load via the capture inspection loader (no MAX_CAPTURE_ENTRIES limit) so we can
119119
# replay real-world captures that commonly exceed 10k entries.
120-
from scripts.inspect_cbor_capture import load_capture_file
120+
from src.core.wire_capture.inspection import load_capture_file
121121

122122
header, entries = load_capture_file(capture_path)
123123

@@ -261,7 +261,7 @@ async def _cmd_detect_repeats(args: argparse.Namespace) -> int:
261261
capture_path = Path(args.capture)
262262
direction = _parse_direction(args.direction)
263263

264-
from scripts.inspect_cbor_capture import load_capture_file
264+
from src.core.wire_capture.inspection import load_capture_file
265265

266266
_header, entries = load_capture_file(capture_path)
267267

@@ -404,7 +404,7 @@ async def _cmd_summarize_streams(args: argparse.Namespace) -> int:
404404
capture_path = Path(args.capture)
405405
direction = _parse_direction(args.direction)
406406

407-
from scripts.inspect_cbor_capture import load_capture_file
407+
from src.core.wire_capture.inspection import load_capture_file
408408

409409
header, entries = load_capture_file(capture_path)
410410

0 commit comments

Comments
 (0)