-
Notifications
You must be signed in to change notification settings - Fork 278
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: expose CreateShareToRowRootProofs for downstream use #3739
Conversation
WalkthroughWalkthroughThe recent changes introduce significant refactoring to the Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant ProofGenerator
participant ShareProofHandler
Client->>ProofGenerator: NewShareInclusionProofFromEDS(...)
ProofGenerator->>ShareProofHandler: CreateShareToRowRootProofs(...)
ShareProofHandler-->>ProofGenerator: Return proofs, raw shares, error
ProofGenerator-->>Client: Return results
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configuration File (
|
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.
Actionable comments posted: 0
Outside diff range, codebase verification and nitpick comments (1)
pkg/proof/proof.go (1)
124-140
: Add test cases forNewShareInclusionProofFromEDS
The function
NewShareInclusionProofFromEDS
is not currently tested. Please add test cases to ensure the refactored logic is properly validated.
- Add unit tests for
NewShareInclusionProofFromEDS
to cover different scenarios and edge cases.Analysis chain
LGTM! But verify the function usage in the codebase.
The code changes are approved.
However, ensure that all function calls to
NewShareInclusionProofFromEDS
are tested with the refactored logic.Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Description: Verify all function calls to `NewShareInclusionProofFromEDS` are tested with the refactored logic. # Test: Search for the function usage. Expect: Only occurances of the new logic. rg --type go -A 5 $'NewShareInclusionProofFromEDS'Length of output: 787
Script:
#!/bin/bash # Description: Verify if `NewShareInclusionProofFromEDS` is tested. # Test: Search for test cases related to `NewShareInclusionProofFromEDS`. rg --type go 'NewShareInclusionProofFromEDS' --testsLength of output: 484
Script:
#!/bin/bash # Description: Verify if `NewShareInclusionProofFromEDS` is tested. # Test: Search for test cases related to `NewShareInclusionProofFromEDS` within test files. rg 'NewShareInclusionProofFromEDS' --type-add 'test:*.go' --type testLength of output: 292
<!-- Please read and fill out this form before submitting your PR. Please make sure you have reviewed our contributors guide before submitting your first PR. --> ## Overview Exposes that functionality so that we don't end up copy-pasting that code in Celestia-node. (cherry picked from commit 8536727) # Conflicts: # pkg/proof/proof.go
<!-- Please read and fill out this form before submitting your PR. Please make sure you have reviewed our contributors guide before submitting your first PR. --> ## Overview Exposes that functionality so that we don't end up copy-pasting that code in Celestia-node. (cherry picked from commit 8536727)
…ort #3739) (#3740) ## Overview Exposes that functionality so that we don't end up copy-pasting that code in Celestia-node.<hr>This is an automatic backport of pull request #3739 done by [Mergify](https://mergify.com). --------- Co-authored-by: sweexordious <chamirachid1@gmail.com>
…ort #3739) (#3741) ## Overview Exposes that functionality so that we don't end up copy-pasting that code in Celestia-node.<hr>This is an automatic backport of pull request #3739 done by [Mergify](https://mergify.com). Co-authored-by: CHAMI Rachid <chamirachid1@gmail.com>
<!-- Please read and fill out this form before submitting your PR. Please make sure you have reviewed our contributors guide before submitting your first PR. --> ## Overview Exposes that functionality so that we don't end up copy-pasting that code in Celestia-node.
Overview
Exposes that functionality so that we don't end up copy-pasting that code in Celestia-node.