Skip to content

RTPRecorder.get_metrics()['packets_received'] counts the port, not the SSRC #10

Description

@mijahauan

RTPRecorder.get_metrics()['packets_received'] should count the caller's channel, not the host's port. It counts every datagram arriving on the bound port before the SSRC filter runs (ka9q/rtp_recorder.py::_receive_loop increments metrics.packets_received immediately after recvfrom, while _validate_packet — which drops wrong-SSRC packets — is called afterwards). Because the recorder binds 0.0.0.0:<channel.port> and every radiod channel on a station publishes to port 5004, the counter is a measure of the whole host. Live DASI002, 2026-08-23: a 60 s single-SSRC capture that wrote 6,000 packets reported packets_received: 72,864 — a 12.1× overcount contributed by the station's other channels. packets_dropped, sequence_errors and timestamp_jumps are correctly per-SSRC (they are computed inside _validate_packet), so one field in the same dict has different semantics from its neighbours, with nothing saying so. A client using packets_received as its capture's denominator computes a completeness figure that is silently wrong.

Docs page(s) blocked/affected: sigmond/docs/scientist/capture-quickstart.md §The sidecar

Provenance: docs-gap ledger row 40, HamSCI/sigmond docs/contributor/docs-gap-ledger.md (2026-08 documentation program, Phase 2).

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdocs-gapfound by the 2026-08 documentation program

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions