fix: replace non-existent SwitchboardWallet with Wallet, add Default impl, fix clippy#38
Open
knoal wants to merge 2 commits into
Open
fix: replace non-existent SwitchboardWallet with Wallet, add Default impl, fix clippy#38knoal wants to merge 2 commits into
knoal wants to merge 2 commits into
Conversation
…impl, fix clippy issues - Replace invalid import of crate::wallet::switchboard::SwitchboardWallet with crate::wallet::Wallet throughout src/cr8/mod.rs and tests - Add impl Default for CR8ClientBuilder (clippy new-without-default) - Add #[allow(dead_code)] on DefaultCR8Client (fields unused due to TODO stubs) - Fix clippy::question_mark in src/mcp/mod.rs (let id = id?) - Fix unused variable warnings in deposit/withdraw (_amount prefix) - Replace ArbitrumSepolia → Arbitrum in tests (chain doesn't exist) - Run cargo fmt to normalize formatting
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes several issues in PR #30 (feat: implement CR8Client trait and builder per spec):
Non-existent type:
SwitchboardWalletdoesn't exist incrate::wallet. Replaced all occurrences with the actualWallettype throughoutsrc/cr8/mod.rsandsrc/cr8/tests.rs.Missing Default impl: Added
impl Default for CR8ClientBuilderto satisfyclippy::new-without-default.Dead code warning: Added
#[allow(dead_code)]onDefaultCR8Clientstruct since its fields are legitimately unused while methods are TODO stubs.clippy::question_mark in mcp/mod.rs: Replaced multi-line
let Some(id) = id else { return None; }withlet id = id?;as suggested by clippy. This is the same pre-existing fix mentioned in PR feat(mpp): implement x402 payment-offer + signed payment-proof core #35's description.Unused variables: Prefixed unused
amountparams indeposit/withdrawwith underscore (_amount).Wrong chain variant: Replaced
Chain::ArbitrumSepolia→Chain::Arbitrumin tests (theSepoliavariant doesn't exist on this branch).All checks pass:
cargo fmt --check,cargo clippy --all-features -- -D warnings,cargo test(32 tests).