-
Notifications
You must be signed in to change notification settings - Fork 1.2k
refactor: replace size check with is_single_member() method for clarity #6908
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: replace size check with is_single_member() method for clarity #6908
Conversation
|
WalkthroughThis change adds Sequence Diagram(s)sequenceDiagram
participant Caller
participant Params as LLMQParams
participant Single as Single-member flow
participant Multi as Multi-member flow
Note over Params: New method: is_single_member()
Caller->>Params: params.is_single_member()
alt is_single_member == true
Params-->>Caller: true
Caller->>Single: Single-member handling
Single-->>Caller: verify member signature / emit operator pubKeyShare / finalize commitment
else is_single_member == false
Params-->>Caller: false
Caller->>Multi: Multi-member handling
Multi-->>Caller: verify aggregated signatures / check quorumVvecHash / queue or secure-aggregate paths
end
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (5)
🚧 Files skipped from review as they are similar to previous changes (2)
🧰 Additional context used📓 Path-based instructions (1)src/**/*.{cpp,h,cc,cxx,hpp}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
🧠 Learnings (2)📓 Common learnings📚 Learning: 2025-08-19T15:08:00.835ZApplied to files:
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🔇 Additional comments (4)
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. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK 2f540be
| ss3.str(), quorumPublicKey.ToString(), commitmentHash.ToString()); | ||
| } | ||
| if (llmq_params.size == 1) { | ||
| if (llmq_params.is_single_member()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's change this one too
Line 141 in 2f540be
| if (llmq_params.size != 1 && quorumVvecHash.IsNull()) { |
2f540be to
90a3b57
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK 90a3b57
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK 90a3b57
Issue being fixed or feature implemented
Avoiding using raw size as indication for special logic; use a helper function in-case the conditions change in the future (however unlikely that may be)
What was done?
added helper for
is_single_memberHow Has This Been Tested?
builds
Breaking Changes
Checklist:
Go over all the following points, and put an
xin all the boxes that apply.