Skip to content

fix(sdk): remove unused Sdk::parse_proof and Sdk::parse_proof_with_metadata#3141

Merged
PastaPastaPasta merged 1 commit into
dashpay:v3.1-devfrom
thepastaclaw:fix/remove-dead-parse-proof-methods
Feb 21, 2026
Merged

fix(sdk): remove unused Sdk::parse_proof and Sdk::parse_proof_with_metadata#3141
PastaPastaPasta merged 1 commit into
dashpay:v3.1-devfrom
thepastaclaw:fix/remove-dead-parse-proof-methods

Conversation

@thepastaclaw
Copy link
Copy Markdown
Collaborator

@thepastaclaw thepastaclaw commented Feb 21, 2026

Summary

Remove unused Sdk::parse_proof and Sdk::parse_proof_with_metadata methods from packages/rs-sdk/src/sdk.rs.

These two methods became dead code — their last external caller (in fetch_many.rs) was removed when the fetch paths were refactored to call parse_proof_with_metadata_and_proof directly. The methods only called each other internally, with no external entry points remaining.

The mock's MockDashPlatformSdk::parse_proof_with_metadata (in mock/sdk.rs) is a separate method and is unaffected.

Changes

  • Removed Sdk::parse_proof (wrapper that discarded metadata)
  • Removed Sdk::parse_proof_with_metadata (wrapper that discarded proof)
  • 44 lines deleted, 0 added

Verification

  • cargo clippy --package dash-sdk --all-features --locked -- --no-deps -D warnings — clean
  • cargo fmt --check --package=dash-sdk — clean

Summary by CodeRabbit

  • Refactor
    • Removed internal helper methods for parsing proof-derived objects. Code paths previously using these methods will require updates to use alternative approaches directly.

…_metadata

These methods became dead code when their last external caller in
fetch_many.rs was removed. Only parse_proof_with_metadata_and_proof
is used by the fetch/fetch_many paths now.
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Feb 21, 2026

📝 Walkthrough

Walkthrough

Two internal helper methods (parse_proof and parse_proof_with_metadata) were removed from the SDK. These methods previously delegated to parse_proof_with_metadata_and_proof, eliminating intermediate wrapper functions that retrieved and returned parsed objects from proofs.

Changes

Cohort / File(s) Summary
Internal Method Removal
packages/rs-sdk/src/sdk.rs
Removed two pub(crate) helper methods that delegated proof parsing to parse_proof_with_metadata_and_proof, consolidating proof parsing logic by eliminating intermediate wrapper functions.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐰 Two helpers hop away,
Delegation's had its day,
Direct paths now shine so bright,
Simpler code, a cleaner sight! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title accurately describes the main change: removing two unused helper methods (parse_proof and parse_proof_with_metadata) from the SDK.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 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.

@github-actions github-actions Bot added this to the v3.1.0 milestone Feb 21, 2026
@thepastaclaw thepastaclaw changed the title clippy(sdk): remove unused Sdk::parse_proof and Sdk::parse_proof_with_metadata fix(sdk): remove unused Sdk::parse_proof and Sdk::parse_proof_with_metadata Feb 21, 2026
Copy link
Copy Markdown
Member

@PastaPastaPasta PastaPastaPasta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fixes a real CI issue which is currently "blocking" for me/claw. I've reviewed the changes. This is not a breaking change, as this is not exposed publicly. I believe this is safe to merge.

@PastaPastaPasta PastaPastaPasta merged commit b445b6f into dashpay:v3.1-dev Feb 21, 2026
44 of 46 checks passed
shumkov added a commit that referenced this pull request Mar 4, 2026
… parse_proof method

The revert commit d820fe2 brought back a custom Document FetchMany::fetch_many
implementation that called Sdk::parse_proof, which was removed in #3141. This
caused compilation failures across dash-sdk, wasm-sdk, rs-sdk-ffi, and iOS builds.

Remove the custom override entirely so the trait's default
fetch_many_with_metadata_and_proof implementation (which correctly uses
parse_proof_with_metadata_and_proof) is used instead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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