oss-slu / oss-slu/PilotDataSynchronization

TCP thread never reports status, so the throughput indicator can never appear

Open
#181 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug rust
Dominant language
Rust
Stars
4
Forks
8
Avg merge
5d 17h
Merged PRs (30d)
2

Description

Describe the bug
FromTcpThreadMessage::{Connected, Disconnected, Sent, SendError} are declared (relay/src/message.rs:57-66) and handled (relay/src/update.rs:71-85), but never constructed anywhere. The TCP thread never calls send_to_parent.

Two consequences:

  1. on_tcp_packet_sent is only called from the unreachable Sent arm, so show_metrics stays false forever and the throughput block always early-returns (relay/src/view.rs:92-95). The packet rate indicator added in #109 cannot ever display.
  2. state.tcp_connected is only updated by pressing Check TCP Connection Status (relay/src/update.rs:106-109), so the status line shows stale data until manually polled.

Expected behavior
The TCP thread reports connect, disconnect, and send events, so the throughput indicator works and the status line updates on its own.

Additional context
This makes the acceptance criteria of #109 unmet in the shipped code. The whole metrics subsystem (packets_last_60s, bps, sent_packet_times, human_bps) is currently unreachable.

Found while writing the setup documentation in #138 / #178.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the message declarations in relay/src/message.rs:57-66 and their handling in relay/src/update.rs:71-85, then locate the TCP thread and its send_to_parent calls. Confirm that connect, disconnect, and send events reach the update logic so the throughput block in relay/src/view.rs:92-95 can appear and the TCP status updates without manual polling.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
networking
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.