Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughWorkspace dependency revisions; Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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.
🧹 Nitpick comments (1)
packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rs (1)
67-71: Consider handlingSome(None)case for service removal.The double-Option handling correctly distinguishes between "field not updated" (
None) and "field updated to a value" (Some(Some(address))). However, whendmn_state_diff.serviceisSome(None)(service explicitly removed), the code doesn't updatenode_ip, leaving potentially stale data.If a masternode's service address being removed should clear or invalidate the validator's IP, this case needs handling. If stale data is acceptable in this scenario, this is fine as-is.
💡 Optional: Handle service removal explicitly
if let Some(maybe_address) = dmn_state_diff.service { if let Some(address) = maybe_address { validator.node_ip = address.ip().to_string(); + } else { + // Service was explicitly removed - consider clearing or marking as unavailable + validator.node_ip = String::new(); // or keep as-is if stale is acceptable } }🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rs` around lines 67 - 71, The code currently only updates validator.node_ip when dmn_state_diff.service is Some(Some(address)); add explicit handling for Some(None) to clear or invalidate the stored IP to avoid stale data: match on dmn_state_diff.service and on Some(None) set validator.node_ip to an appropriate "cleared" value (e.g., empty string or None if the field is Option<String>), keep the existing behavior for Some(Some(address)) to set validator.node_ip = address.ip().to_string(), and leave None as "no change". Use the symbols dmn_state_diff.service and validator.node_ip to locate and modify the logic.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In
`@packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rs`:
- Around line 67-71: The code currently only updates validator.node_ip when
dmn_state_diff.service is Some(Some(address)); add explicit handling for
Some(None) to clear or invalidate the stored IP to avoid stale data: match on
dmn_state_diff.service and on Some(None) set validator.node_ip to an appropriate
"cleared" value (e.g., empty string or None if the field is Option<String>),
keep the existing behavior for Some(Some(address)) to set validator.node_ip =
address.ip().to_string(), and leave None as "no change". Use the symbols
dmn_state_diff.service and validator.node_ip to locate and modify the logic.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 75fdf756-931b-4656-87e3-107cc97f3f73
⛔ Files ignored due to path filters (1)
Cargo.lockis excluded by!**/*.lock
📒 Files selected for processing (15)
Cargo.tomlpackages/rs-dpp/Cargo.tomlpackages/rs-dpp/src/lib.rspackages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rspackages/rs-drive-abci/src/platform_types/masternode/v0/mod.rspackages/rs-drive-abci/src/platform_types/validator/v0/mod.rspackages/rs-drive-abci/tests/strategy_tests/masternodes.rspackages/rs-platform-wallet/Cargo.tomlpackages/rs-platform-wallet/README.mdpackages/rs-platform-wallet/examples/basic_usage.rspackages/rs-platform-wallet/src/lib.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_info_interface.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_transaction_checker.rspackages/rs-sdk-ffi/build_ios.shpackages/rs-sdk-ffi/src/unified.rs
...form_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rs
Outdated
Show resolved
Hide resolved
…sactionContext) - Update all rust-dashcore deps from 42eb1d69 to 08ade6e8 - Remove key-wallet-manager from workspace deps (merged into key-wallet::manager) - Remove "std" feature from dashcore dep (no longer exists) - Fix key-wallet-manager imports → key-wallet::manager in dpp, platform-wallet - Fix DMNState.service: SocketAddr → Option<SocketAddr> in drive-abci - Fix double-Option in dmn_state_diff.service handling - Fix dash_spv_ffi_client_new: add FFIEventCallbacks parameter in rs-sdk-ffi - Add mark_instant_send_utxos to PlatformWalletInfo WalletInfoInterface impl - Update test code for new API signatures Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
448b14e to
ba359d2
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/rs-sdk-ffi/src/unified.rs`:
- Around line 75-76: The build uses the wrong feature flag so conditional blocks
(e.g., the cleanup guarded by #[cfg(feature = "core")]) never run; update every
occurrence of #[cfg(feature = "core")] in unified.rs to #[cfg(feature =
"dash_spv")] so the dash_spv-dependent code (including resource cleanup around
dash_spv_ffi_client_new and FFIEventCallbacks usage) is compiled and the
resources are released correctly.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 6b6efafd-9772-4452-8a25-a962154029a9
⛔ Files ignored due to path filters (1)
Cargo.lockis excluded by!**/*.lock
📒 Files selected for processing (20)
Cargo.tomlpackages/rs-dpp/Cargo.tomlpackages/rs-dpp/src/lib.rspackages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_identities/update_operator_identity/v0/mod.rspackages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rspackages/rs-drive-abci/src/execution/validation/state_transition/state_transitions/mod.rspackages/rs-drive-abci/src/platform_types/masternode/mod.rspackages/rs-drive-abci/src/platform_types/masternode/v0/mod.rspackages/rs-drive-abci/src/platform_types/validator/v0/mod.rspackages/rs-drive-abci/tests/strategy_tests/masternode_list_item_helpers.rspackages/rs-drive-abci/tests/strategy_tests/masternodes.rspackages/rs-platform-wallet/Cargo.tomlpackages/rs-platform-wallet/README.mdpackages/rs-platform-wallet/examples/basic_usage.rspackages/rs-platform-wallet/src/lib.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_info_interface.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_transaction_checker.rspackages/rs-sdk-ffi/build_ios.shpackages/rs-sdk-ffi/src/unified.rspackages/rs-sdk/Cargo.toml
💤 Files with no reviewable changes (2)
- packages/rs-platform-wallet/src/lib.rs
- packages/rs-dpp/src/lib.rs
✅ Files skipped from review due to trivial changes (6)
- packages/rs-platform-wallet/README.md
- packages/rs-platform-wallet/examples/basic_usage.rs
- packages/rs-drive-abci/tests/strategy_tests/masternodes.rs
- packages/rs-drive-abci/src/platform_types/validator/v0/mod.rs
- packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_identities/update_operator_identity/v0/mod.rs
- packages/rs-platform-wallet/Cargo.toml
🚧 Files skipped from review as they are similar to previous changes (4)
- Cargo.toml
- packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rs
- packages/rs-platform-wallet/src/platform_wallet_info/wallet_info_interface.rs
- packages/rs-platform-wallet/src/platform_wallet_info/wallet_transaction_checker.rs
| let core_client = | ||
| dash_spv_ffi::dash_spv_ffi_client_new(config.core_config, FFIEventCallbacks::default()); |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Verify FFIEventCallbacks struct and its Default implementation in dash_spv_ffi
# Search for FFIEventCallbacks definition and Default impl
rg -n -C5 'struct FFIEventCallbacks' --type rust
# Search for Default implementation
rg -n -C5 'impl.*Default.*for.*FFIEventCallbacks' --type rust
# Search for dash_spv_ffi_client_new function signature
rg -n -C3 'fn dash_spv_ffi_client_new' --type rustRepository: dashpay/platform
Length of output: 42
🏁 Script executed:
# First, let's examine the file being reviewed
cat -n packages/rs-sdk-ffi/src/unified.rs | head -100
# Check for imports related to FFIEventCallbacks and dash_spv_ffi
rg -n 'FFIEventCallbacks|dash_spv_ffi' packages/rs-sdk-ffi/src/unified.rs
# Look for the struct definition - it might be in a different file
fd -e rs | xargs rg -l 'FFIEventCallbacks' | head -10
# Search for dash_spv_ffi_client_new without type restriction
rg -n 'dash_spv_ffi_client_new' --type-list | head -5
rg -n 'dash_spv_ffi_client_new' 2>/dev/null | head -20Repository: dashpay/platform
Length of output: 5058
🏁 Script executed:
# Search for FFIEventCallbacks definition in all file types
rg -n 'struct FFIEventCallbacks\|impl.*Default.*FFIEventCallbacks' -i
# Check Cargo.toml for dash_spv_ffi dependency configuration
cat packages/rs-sdk-ffi/Cargo.toml | grep -A5 -B5 'dash_spv_ffi'
# Check for any feature-conditional imports
rg -n '#\[cfg.*core' packages/rs-sdk-ffi/src/unified.rs
# Look for pub use or re-exports of FFIEventCallbacks
rg -n 'pub.*FFIEventCallbacks|use.*FFIEventCallbacks' packages/rs-sdk-ffi/src/Repository: dashpay/platform
Length of output: 916
🏁 Script executed:
# Read Cargo.toml to see dash_spv_ffi dependency configuration
cat packages/rs-sdk-ffi/Cargo.toml
# Also check if there's a feature definition in Cargo.toml
grep -A20 '\[features\]' packages/rs-sdk-ffi/Cargo.tomlRepository: dashpay/platform
Length of output: 2979
🏁 Script executed:
# Search for "core" feature definition in Cargo.toml files
find . -name "Cargo.toml" -type f | xargs grep -l 'features.*core\|^\[features\]' | head -10
# Check workspace Cargo.toml
cat Cargo.toml 2>/dev/null | grep -A30 '\[features\]' | head -40
# Look for any comments explaining the feature mapping
rg -n 'feature.*core|feature.*dash_spv' packages/rs-sdk-ffi/src/ -B2 -A2
# Check if there are other Cargo.toml files in parent directories
ls -la Cargo.tomlRepository: dashpay/platform
Length of output: 10540
🏁 Script executed:
# Check workspace Cargo.toml for feature definitions
cat Cargo.toml | grep -A50 '\[features\]'
# Check if "core" feature is defined elsewhere
rg -n 'core.*=.*\[' --type toml | grep featuresRepository: dashpay/platform
Length of output: 133
🏁 Script executed:
# Get the workspace Cargo.toml features section more carefully
head -150 Cargo.toml | tail -100
# Check if there's a [workspace] section with features
grep -A100 '\[workspace\]' Cargo.toml | head -80
# Search for any definition of "core" feature in workspace or packages
rg 'features.*=.*\[' Cargo.toml | grep coreRepository: dashpay/platform
Length of output: 5900
🏁 Script executed:
# Check if the conditional blocks are actually being compiled
# by looking at what happens when "dash_spv" is disabled
rg -n 'cfg.*dash_spv' packages/rs-sdk-ffi/src/
# Verify what feature gates actually exist in the code
rg -n 'cfg.*feature' packages/rs-sdk-ffi/src/ | grep -E '\bcore\b|\bdash_spv\b'Repository: dashpay/platform
Length of output: 3427
🏁 Script executed:
# Check if there are any aliases or mappings for "core" feature
rg -n 'core.*=' Cargo.toml
# Try to understand if there's a build script that creates the feature
cat packages/rs-sdk-ffi/build.rs 2>/dev/null || echo "No build.rs found"
# Check the actual compilation to see if it would fail
cd packages/rs-sdk-ffi && cargo metadata 2>&1 | grep -A10 '"features"' | head -20Repository: dashpay/platform
Length of output: 146
Critical: Feature name mismatch prevents proper resource cleanup.
The code uses #[cfg(feature = "core")] throughout (lines 82-85 and many others), but this feature is never defined in Cargo.toml. The actual feature is dash_spv (enabled by default).
Since the non-existent "core" feature evaluates to false, the cleanup code at lines 82-85 and throughout the file will never execute, causing resource leaks. The unconditional call at lines 75-76 will run, but cleanup won't.
Change #[cfg(feature = "core")] to #[cfg(feature = "dash_spv")] throughout the unified.rs file.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@packages/rs-sdk-ffi/src/unified.rs` around lines 75 - 76, The build uses the
wrong feature flag so conditional blocks (e.g., the cleanup guarded by
#[cfg(feature = "core")]) never run; update every occurrence of #[cfg(feature =
"core")] in unified.rs to #[cfg(feature = "dash_spv")] so the dash_spv-dependent
code (including resource cleanup around dash_spv_ffi_client_new and
FFIEventCallbacks usage) is compiled and the resources are released correctly.
babff9a to
1c7490f
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## v3.1-dev #3405 +/- ##
============================================
- Coverage 79.93% 79.93% -0.01%
============================================
Files 2861 2861
Lines 280230 280235 +5
============================================
+ Hits 223993 223994 +1
- Misses 56237 56241 +4
🚀 New features to boost your workflow:
|
1c7490f to
e96f8be
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/rs-sdk-ffi/include/dash_sdk_ffi.h`:
- Around line 14-15: Remove the duplicated system includes in dash_sdk_ffi.h:
the second occurrence of `#include` <stdint.h> and `#include` <stdbool.h> (lines
matching the ones in the diff) should be deleted so each header is included only
once; keep the original includes already present (the first occurrence) and
ensure there are no other accidental duplicate includes in the file.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 5c31c502-76ef-46dd-b890-0dab8c25729b
⛔ Files ignored due to path filters (1)
Cargo.lockis excluded by!**/*.lock
📒 Files selected for processing (22)
Cargo.tomlpackages/rs-dpp/Cargo.tomlpackages/rs-dpp/src/lib.rspackages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_identities/update_operator_identity/v0/mod.rspackages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rspackages/rs-drive-abci/src/execution/validation/state_transition/state_transitions/mod.rspackages/rs-drive-abci/src/platform_types/masternode/mod.rspackages/rs-drive-abci/src/platform_types/masternode/v0/mod.rspackages/rs-drive-abci/src/platform_types/validator/v0/mod.rspackages/rs-drive-abci/tests/strategy_tests/masternode_list_item_helpers.rspackages/rs-drive-abci/tests/strategy_tests/masternodes.rspackages/rs-platform-wallet/Cargo.tomlpackages/rs-platform-wallet/README.mdpackages/rs-platform-wallet/examples/basic_usage.rspackages/rs-platform-wallet/src/lib.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_info_interface.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_transaction_checker.rspackages/rs-sdk-ffi/build.rspackages/rs-sdk-ffi/build_ios.shpackages/rs-sdk-ffi/include/dash_sdk_ffi.hpackages/rs-sdk-ffi/src/unified.rspackages/rs-sdk/Cargo.toml
💤 Files with no reviewable changes (2)
- packages/rs-platform-wallet/src/lib.rs
- packages/rs-dpp/src/lib.rs
✅ Files skipped from review due to trivial changes (5)
- packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_identities/update_operator_identity/v0/mod.rs
- packages/rs-platform-wallet/README.md
- packages/rs-platform-wallet/examples/basic_usage.rs
- packages/rs-platform-wallet/Cargo.toml
- packages/rs-drive-abci/tests/strategy_tests/masternodes.rs
🚧 Files skipped from review as they are similar to previous changes (9)
- packages/rs-drive-abci/src/platform_types/validator/v0/mod.rs
- packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rs
- packages/rs-drive-abci/src/platform_types/masternode/mod.rs
- packages/rs-drive-abci/tests/strategy_tests/masternode_list_item_helpers.rs
- packages/rs-platform-wallet/src/platform_wallet_info/wallet_info_interface.rs
- packages/rs-sdk-ffi/src/unified.rs
- packages/rs-sdk/Cargo.toml
- packages/rs-drive-abci/src/platform_types/masternode/v0/mod.rs
- Cargo.toml
e96f8be to
7edd22d
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (2)
packages/rs-drive-abci/src/platform_types/masternode/v0/mod.rs (1)
164-166: Consider a more actionable error message.The current message correctly identifies the problem, but could help operators diagnose the issue faster by mentioning the required Core RPC flag. Per the prior discussion, this occurs when
-deprecatedrpc=serviceis not passed.💡 Suggested improvement
- let service = service.ok_or(Error::Execution(ExecutionError::CorruptedCodeExecution( - "masternode service address is required but was empty in core RPC response", - )))?; + let service = service.ok_or(Error::Execution(ExecutionError::CorruptedCodeExecution( + "masternode service address is required but was empty in core RPC response; ensure -deprecatedrpc=service is passed to dashd", + )))?;🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/rs-drive-abci/src/platform_types/masternode/v0/mod.rs` around lines 164 - 166, The error raised when `service` is missing (where code constructs Error::Execution(ExecutionError::CorruptedCodeExecution(...))) should be made actionable: update the error string to mention that the Core RPC flag `-deprecatedrpc=service` may be missing and must be enabled, so operators know what to pass to Core RPC; locate the `service` unwrapping in mod.rs (the `service = service.ok_or(...)` line) and replace the current message with one that includes guidance to set `-deprecatedrpc=service` along with the original context.packages/rs-sdk-ffi/build_ios.sh (1)
189-219: Consider logging a warning when header generation fails.The header generation code continues silently after failure (lines 203-206, 213-215), relying on later fallback patching. While this is likely intentional for resilience, a warning message noting that fallback patching will be attempted would help developers understand the build flow:
💡 Suggested improvement
if $DASHCORE_CARGO_CMD build --release -p key-wallet-ffi > /tmp/cargo_build_kwffi_host.log 2>&1; then echo -e " ${GREEN}done${NC}" else echo -e " ${RED}failed${NC}" cat /tmp/cargo_build_kwffi_host.log + echo -e "${YELLOW} Will use fallback patching if needed${NC}" fi🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/rs-sdk-ffi/build_ios.sh` around lines 189 - 219, When generation of FFI headers fails in the host build (the branches that build key-wallet-ffi and dash-spv-ffi using DASHCORE_CARGO_CMD), add an explicit warning log immediately after the existing failure handling (where it currently echoes failed and cats the log) that clearly states header generation for KEY_WALLET_HEADER_PATH or SPV_HEADER_PATH failed and that the script will attempt fallback patching; update both failure blocks to include this warning message referencing the failed header variable and the log file (/tmp/cargo_build_kwffi_host.log or /tmp/cargo_build_spvffi_host.log) so developers see that fallback behavior will be used.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/rs-sdk-ffi/build_ios.sh`:
- Around line 383-400: The injected fallback in build_ios.sh can produce a
redefinition for FFIDashSpvClient and mismatches the original opaque field;
change the injected block that currently prints "typedef struct FFIDashSpvClient
{ unsigned char _private[0]; } FFIDashSpvClient;" to emit a pure forward
declaration (e.g., "typedef struct FFIDashSpvClient FFIDashSpvClient;" or
"struct FFIDashSpvClient; typedef struct FFIDashSpvClient FFIDashSpvClient;")
instead, so locate the awk rule in the script that matches '#include
"dash_spv_ffi.h"' and replace the full typedef lines with the
forward-declaration lines for FFIDashSpvClient (and remove or avoid introducing
any differing opaque field names like _private) to prevent redefinition and
type-name mismatches in dash_sdk_ffi.h.
---
Nitpick comments:
In `@packages/rs-drive-abci/src/platform_types/masternode/v0/mod.rs`:
- Around line 164-166: The error raised when `service` is missing (where code
constructs Error::Execution(ExecutionError::CorruptedCodeExecution(...))) should
be made actionable: update the error string to mention that the Core RPC flag
`-deprecatedrpc=service` may be missing and must be enabled, so operators know
what to pass to Core RPC; locate the `service` unwrapping in mod.rs (the
`service = service.ok_or(...)` line) and replace the current message with one
that includes guidance to set `-deprecatedrpc=service` along with the original
context.
In `@packages/rs-sdk-ffi/build_ios.sh`:
- Around line 189-219: When generation of FFI headers fails in the host build
(the branches that build key-wallet-ffi and dash-spv-ffi using
DASHCORE_CARGO_CMD), add an explicit warning log immediately after the existing
failure handling (where it currently echoes failed and cats the log) that
clearly states header generation for KEY_WALLET_HEADER_PATH or SPV_HEADER_PATH
failed and that the script will attempt fallback patching; update both failure
blocks to include this warning message referencing the failed header variable
and the log file (/tmp/cargo_build_kwffi_host.log or
/tmp/cargo_build_spvffi_host.log) so developers see that fallback behavior will
be used.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 832371a3-ca2b-4368-bcf0-01c43c4fe2de
⛔ Files ignored due to path filters (1)
Cargo.lockis excluded by!**/*.lock
📒 Files selected for processing (22)
Cargo.tomlpackages/rs-dpp/Cargo.tomlpackages/rs-dpp/src/lib.rspackages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_identities/update_operator_identity/v0/mod.rspackages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rspackages/rs-drive-abci/src/execution/validation/state_transition/state_transitions/mod.rspackages/rs-drive-abci/src/platform_types/masternode/mod.rspackages/rs-drive-abci/src/platform_types/masternode/v0/mod.rspackages/rs-drive-abci/src/platform_types/validator/v0/mod.rspackages/rs-drive-abci/tests/strategy_tests/masternode_list_item_helpers.rspackages/rs-drive-abci/tests/strategy_tests/masternodes.rspackages/rs-platform-wallet/Cargo.tomlpackages/rs-platform-wallet/README.mdpackages/rs-platform-wallet/examples/basic_usage.rspackages/rs-platform-wallet/src/lib.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_info_interface.rspackages/rs-platform-wallet/src/platform_wallet_info/wallet_transaction_checker.rspackages/rs-sdk-ffi/build.rspackages/rs-sdk-ffi/build_ios.shpackages/rs-sdk-ffi/include/dash_sdk_ffi.hpackages/rs-sdk-ffi/src/unified.rspackages/rs-sdk/Cargo.toml
💤 Files with no reviewable changes (2)
- packages/rs-dpp/src/lib.rs
- packages/rs-platform-wallet/src/lib.rs
✅ Files skipped from review due to trivial changes (4)
- packages/rs-platform-wallet/README.md
- packages/rs-drive-abci/src/execution/validation/state_transition/state_transitions/mod.rs
- packages/rs-sdk-ffi/src/unified.rs
- packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_identities/update_operator_identity/v0/mod.rs
🚧 Files skipped from review as they are similar to previous changes (10)
- packages/rs-drive-abci/src/platform_types/masternode/mod.rs
- packages/rs-platform-wallet/examples/basic_usage.rs
- packages/rs-drive-abci/src/execution/platform_events/core_based_updates/update_masternode_list/update_state_masternode_list/v0/mod.rs
- packages/rs-platform-wallet/src/platform_wallet_info/wallet_info_interface.rs
- packages/rs-drive-abci/tests/strategy_tests/masternodes.rs
- packages/rs-drive-abci/tests/strategy_tests/masternode_list_item_helpers.rs
- packages/rs-sdk/Cargo.toml
- Cargo.toml
- packages/rs-drive-abci/src/platform_types/validator/v0/mod.rs
- packages/rs-sdk-ffi/build.rs
7edd22d to
923a16a
Compare
|
Superseded by #3408 which is based on the latest v3.1-dev. |
Issue being fixed or feature implemented
Update rust-dashcore dependency from
42eb1d69to08ade6e8(v0.42-dev HEAD). This brings in several breaking changes that affect the platform workspace.What was done?
Dashcore dependency update
08ade6e8key-wallet-managerfrom workspace deps — merged intokey-wallet::managerin dashcore"std"feature from dashcore dep in rs-dpp (feature removed upstream)key-wallet-manager → key-wallet migration
key-wallet-managerdep from rs-dpp and rs-platform-wallet Cargo.tomlcore_key_wallet_managerfeature handlingpub use key_wallet_managerre-exports from rs-dpp and rs-platform-walletDMNState.service: SocketAddr → Option<SocketAddr>
DMNState.serviceoptional for Core v24 compatibilityMasternodeStateV0.servicestays asSocketAddr(versioned state cannot change)From<DMNState>toTryFrom<DMNState>— returns error when service is None (requires-deprecatedrpc=serviceflag)Some()WalletInterface changes
process_mempool_transactiongainsis_instant_send: boolparam, returnsMempoolTransactionResultwatched_outpoints()required method to SpvWalletAdaptermark_instant_send_utxos()to PlatformWalletInfo WalletInfoInterface implcheck_core_transactioncaller to pass newupdate_balanceparameterSwift SDK — unified EventHandler API
SPVClientwith unifiedFFIEventCallbacksstruct passed at constructionSPVEventHandlerfor new callback signatures (block processed with confirmed txids, transaction received with status)WalletServiceto pass all handlers at SPVClient constructionbuild_ios.shfallback: use forward declarations instead of full typedefs forFFIDashSpvClientandFFIClientConfigFFIEventCallbacksforward declaration inbuild.rscbindgen configdash_sdk_ffi.hself-contained with forward declarationsrs-sdk-ffi
dash_spv_ffi_client_newcall to passFFIEventCallbacks::default()key-wallet-managerfrombuild_ios.shhash computationHow Has This Been Tested?
cargo check --workspacepasses (Rust compilation)cargo check -p rs-sdk-ffipasses (FFI layer)cargo clippy -p drive-abci -- -D warningspassesBreaking Changes
key-wallet-managercrate no longer exists — usekey_wallet::managerinsteadDMNState.serviceis nowOption<SocketAddr>WalletInterface::process_mempool_transactionsignature changedSPVClientAPI changed: handlers passed at construction, not via setters