Skip to content

fix: handle broadcast RecvError::Lagged gracefully in maintenance loop#448

Closed
thepastaclaw wants to merge 1 commit intodashpay:feat/reactive-peer-recoveryfrom
thepastaclaw:review/433-maintenance-fixes
Closed

fix: handle broadcast RecvError::Lagged gracefully in maintenance loop#448
thepastaclaw wants to merge 1 commit intodashpay:feat/reactive-peer-recoveryfrom
thepastaclaw:review/433-maintenance-fixes

Conversation

@thepastaclaw
Copy link

@thepastaclaw thepastaclaw commented Feb 17, 2026

Addresses review feedback from CodeRabbit on #433:

1. Consistent logging macros
Replaced tracing::error! with log::error! to match the rest of manager.rs which uses the log crate throughout.

2. Handle RecvError::Lagged vs RecvError::Closed separately
Previously, any broadcast::RecvError was treated as fatal (broke the loop). Now:

  • RecvError::Lagged(n): Log a warning with the count and continue. Lagged just means we missed some broadcast events — not fatal.
  • RecvError::Closed: Log an error and break. The channel is gone, maintenance loop should stop.

🤖 This was generated by an automated review bot.
Don't want automated PRs or comments on your code? You can opt out by replying here or messaging @PastaPastaPasta on Slack — we'll make sure the bot skips your PRs/repos going forward.

- Replace tracing::error! with log macros for consistency with the rest
  of the file
- Distinguish RecvError::Lagged from RecvError::Closed: lagged just
  means we missed some events (log warning and continue), while closed
  means the channel is gone (log error and break)
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 17, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@xdustinface xdustinface deleted the branch dashpay:feat/reactive-peer-recovery February 17, 2026 21:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants