chanfitness: seed peer uptime from actual online state#10890
chanfitness: seed peer uptime from actual online state#10890erickcestari wants to merge 2 commits into
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request addresses an issue where channel uptime was incorrectly reported as 100% for channels whose peers were offline at startup. By introducing a mechanism to query the actual connection state of a peer when it is first tracked, the system now accurately reflects connectivity, ensuring that uptime metrics are reliable from the moment the node starts. Highlights
New Features🧠 You can now enable Memory (public preview) to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
279f248 to
450bc1f
Compare
There was a problem hiding this comment.
Code Review
This pull request fixes a bug where ListChannels incorrectly reported 100% uptime for channels whose peers were offline at startup. It introduces an IsPeerOnline callback to the Config of ChannelEventStore to seed the initial online state of a peer from its actual connectivity. The review feedback highlights a potential nil pointer dereference panic if IsPeerOnline is not initialized in external tests or integrations, suggesting a fallback check to prevent this.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
PR Severity: CRITICAL
Critical (1 file)
Medium (1 file)
Low (1 file)
AnalysisThis PR is classified CRITICAL because it modifies The bulk of the changes are in Severity bump check: 3 non-test files (threshold: >20), 24 non-test lines changed (threshold: >500), single critical package touched - no bump applied. To override, add a |
Channels are loaded into the channel fitness store on startup regardless of whether their peer is connected. When a peer monitor was first created we unconditionally recorded an online event, which caused offline peers to report 100% uptime in ListChannels. Seed the initial event with the peer's actual connection state via a new IsPeerOnline config callback so that uptime reflects real connectivity.
450bc1f to
7e070fd
Compare
Channels are loaded into the channel fitness store on startup regardless of whether their peer is connected. When a peer monitor was first created we unconditionally recorded an online event, which caused offline peers to report 100% uptime in
ListChannels.Seed the initial event with the peer's actual connection state via a new
IsPeerOnlineconfig callback so that uptime reflects real connectivity.Closes #10417