Skip to content

chore: update Rust dependencies - #5948

Merged
lklimek merged 13 commits into
v5.2-devfrom
chore/rust-deps-update-v5.2
Nov 17, 2026
Merged

lklimek merged 13 commits into
v5.2-devfrom
chore/rust-deps-update-v5.2

Conversation

@Claudius-Maginificent

@Claudius-Maginificent Claudius-Maginificent commented Nov 16, 2026 •

Copy link
Copy Markdown
Collaborator

TL;DR: Refresh the Rust dependencies for v5.2 — fixing the five security advisories that make the nightly Rust audit fail — while keeping every network-visible behaviour identical.

User story

As a node operator, I want the Platform node built from current, advisory-free dependencies, to run it without known vulnerabilities and without any change in how the network agrees on state.

Scenario

Base flow

Every night CI audits the locked Rust dependencies against the RustSec advisory database.

Actual behavior

The "Security: Rust Crates" workflow fails every night with five advisories (libz-sys, pulldown-cmark ×2, quinn-udp, zstd-sys), and "Security Status" fails after it. Many direct dependencies are several releases behind.

Expected behavior

The audit reports no vulnerabilities, and direct dependencies whose upgrade needs only mechanical code changes are current.

Detailed discussion

What was done

  • Lockfile refresh (cargo update, semver-compatible only). Fixes RUSTSEC-2026-0418, -0414, -0433, -0538 and -0410. Git-pinned dependencies (GroveDB, rust-dashcore, tenderdash-abci) and =-pinned crates are unchanged.

  • ICU kept at 2.2.0. cargo update would move icu_* to 2.4.0 (Unicode 18 data). url → idna → idna_adapter uses that data for UTS-46 host processing, so Url::from_str would accept ~13k more code points. That changes the verdict of format: "uri" in both document validators (native and jsonschema before PV15) and of $schema/$vocabulary at contract registration, with no protocol-version gate. A new rs-dpp test (should_refuse_a_format_uri_value_whose_host_holds_a_code_point_unassigned_in_unicode_17) pins the current verdict at the latest protocol version and at PV14. It fails on ICU 2.4 and passes on 2.2, so a future dependency update that changes this consensus result fails CI.

  • Exact pins only where a consensus change is proven. The ICU4X crates and their data (icu_normalizer, icu_properties and their _data crates) are pinned with = in rs-dpp. They are optional under validation-schema and ignored by cargo-machete, and the pin's comment points to the guard test. Other consensus-reaching crates (sha2, base64, fraction, json-patch, url, derive_more, bech32) were checked by running each against every newer published release with standalone probes, which found no consensus-visible difference. They therefore keep their normal version requirements. ed25519-dalek keeps its existing =2.2.0.

  • Semver-incompatible bumps with at most mechanical changes: thiserror 2 (remaining crates), itertools 0.15, strum 0.28, chrono-tz 0.10, num_enum 0.7 (withdrawals-contract), virtue 0.0.19, enum-map 3, parking_lot 0.13, moka 0.12.16 (drop the removed futures-util feature), criterion 0.8 (std::hint::black_box), mockall 0.15, metrics-exporter-prometheus 0.18, console-subscriber 0.5, file-rotate 0.8 (OpenOptions with mode 0o600, plus a test for the owner-only log file mode), tokio-tungstenite 0.30 (Message::Text(..into())), tower-http 0.7, serial_test 4, lru 0.19, quick_cache 0.7 (rs-dapi), toml 1 (check-features).

  • Not updated. Every direct dependency whose newest release this PR does not take, and why:

    Crate (where) Kept at Newest Why not updated
    icu_normalizer, icu_normalizer_data, icu_properties, icu_properties_data (dpp) =2.2.0 2.4.0 Unicode 18 data changes the format: "uri", $schema and $vocabulary verdicts (see above). Guard test in rs-dpp.
    sha2 (10 crates) 0.10 0.11.1 Reaches consensus (document ids, signable-bytes hash). Probes found identical output, but a consensus crate bump needs its own chain-replay test. It also moves with the RustCrypto family (digest 0.11).
    hmac, aes, cbc, chacha20poly1305, argon2 (platform-encryption, wasm-sdk, wallet-storage) 0.12 / 0.8 / 0.1 / 0.10 / =0.5.3 0.13 / 0.9 / 0.2 / 0.11 / 0.6 RustCrypto family moves together to digest 0.11 / cipher 0.5 (hybrid-array instead of GenericArray). Not mechanical, and it handles wallet encryption.
    ed25519-dalek (dpp) =2.2.0 3.0.0 Existing exact pin kept. Major crypto release; it should move with the RustCrypto family.
    base64 (9 crates) 0.22 0.23.1 API-breaking (DecodeError variants and Debug). Its error text reaches ExecTxResult.info, so it needs a consensus check of its own.
    bech32 (dpp) 0.11 0.12.0 Used in dpp for addresses; a separate bump with tests, not part of a lockfile refresh.
    fraction (dpp) 0.15 0.17.0 Used in consensus arithmetic. Probes found identical results, but it needs a chain-replay test.
    json-patch (json-schema-compatibility-validator) 1.4 5.0.0 2.0+ is API-breaking (jsonptr paths). It decides data-contract update compatibility, which is consensus.
    derive_more (dpp, drive, drive-abci, sdk, proof verifier) 1.0 2.1.1 Major release across consensus crates. Its Display/From derives would need a review crate by crate.
    rand (10 crates) 0.8 0.10.4 API renames (gen→random, thread_rng→rng) and getrandom 0.4. Seeded generators feed deterministic strategy tests and test fixtures, and rust-dashcore/key-wallet still use 0.8.
    getrandom (dpp, dapi-client, wasm-sdk, sdk-ffi, …) 0.2 / 0.3 0.4.3 0.3+ replaces the js feature with the wasm_js backend and a --cfg flag, which changes the wasm build setup.
    syn (5 proc-macro crates) 2 3.0.10 Major rewrite of the proc-macro AST API.
    reqwest (rs-dapi, trusted-context-provider) 0.12 0.13.5 Changes the default TLS backend.
    reqwest-middleware, reqwest-tracing (rs-dapi) 0.4 / 0.5 0.5.2 / 0.7.1 Require reqwest 0.13.
    sqlparser (drive) 0.38 0.64.0 Many breaking AST changes between releases.
    jni (rs-unified-sdk-jni) 0.21 0.22.4 Rewritten API (Env/references).
    android_logger (rs-unified-sdk-jni) 0.14 0.15.1 Android-only code; no Android Rust build in CI compiles it.
    bip39 (wasm-sdk) 2.0 3.0.0 Pulls unicode-normalization 0.1.26 (Unicode 18). NFKD of a BIP39 passphrase could change, so an existing wallet could derive a different seed.
    rusqlite (platform-wallet, wallet-storage) 0.41 0.43.0 Needs a refinery release that supports it.
    nonempty (drive-abci), zip32 (platform-wallet) 0.11 / 0.2 0.12 / 0.3 Must match orchard, a git dependency.
    wasm-bindgen (wasm crates) =0.2.108 0.2.130 Must equal wasm-bindgen-cli in CI and the Dockerfile.
    gloo-timers (dapi-client, trusted-context-provider) 0.3 0.4.1 Requires wasm-bindgen ≥ 0.2.114.
    wasm-streams (trusted-context-provider) 0.5 0.7.1 0.7 needs wasm-bindgen ≥ 0.2.128 for #[wasm_bindgen(private)]. With the pinned 0.2.108, the generated wasm-sdk typings stop exporting ChainedDocumentsQuery, and the evo-sdk TypeScript build fails.
    cbindgen (sdk-ffi, wallet-ffi) 0.27 0.29.4 Changes the generated FFI headers that the Swift SDK consumes.
    time, zeroize, region, keyring-core, apple-native-keyring-store, windows-native-keyring-store, dbus-secret-service-keyring-store (wallet-storage) = pins newer Deliberate exact pins on the secret-storage stack (a human reads each diff); time matches refinery's types.
  • Held in the lockfile below the newest compatible release:

    • halo2_proofs 0.3.2, bitvec 1.0.1, blake2b_simd 1.0.4, pasta_curves 0.5.1: they sit under Orchard proof verification. A bump needs old/new proof, root and serialization vectors.
    • unicode-normalization 0.1.25: see bip39 above (also used by key-wallet).
    • tonic-web-wasm-client 0.9.1: 0.9.2 pulls wasm-streams 0.7 (see above).
    • tokio 1.53.3 (newest 1.54.1): 1.54.1 deadlocks the platform-wallet test should_not_take_the_store_as_read_by_a_pass_a_sender_was_unignored_under. 1.53.3 has no advisory; 1.52.3 is flagged unsound (RUSTSEC-2026-0386).

Stacked on #5952 (merge of v5.1-dev into v5.2-dev); retarget to v5.2-dev after it merges. #5951 is stacked on this PR.

Branch history: the branch starts at 0fc32ab8fa, the merge-base of v5.1-dev and v5.2-dev, and has v5.1-dev merged in. So it carries v5.1-dev's git dependency updates (Tenderdash 2.0.0-dev.2, GroveDB 89dc7351, rust-dashcore f6bb90cb, dashcore-crypto replacing bls-signatures). Merge resolution: crates.io versions come from this branch, git dependencies and workspace versions from v5.1-dev, and ICU stays at 2.2.0.

Consensus review: the bumped crates used by consensus code (strum, itertools, num_enum, virtue, enum-map, thiserror) and the lockfile-only updates of serde_json, regex/regex-automata, num-bigint, uuid and iso8601 were compared at source level against their previous versions. A differential run of 1.6M regex match results between the old and new versions was byte-identical.

Testing

  • cargo clippy --workspace --all-targets -- -D warnings: clean.
  • wasm32 clippy (wasm-sdk, wasm-dpp, wasm-dpp2, wasm-drive-verify, rs-sdk-trusted-context-provider): clean.
  • Tests for every crate where code changed: rs-dapi (445), drive-abci logging, dpp/drive/withdrawals-contract validation and fee tests, dpp validate_document.
  • cargo fmt --check: clean. cargo audit: 0 vulnerabilities; the 2 remaining warnings predate this PR (atomic-polyfill, and scc via zeromq).
  • Not run locally:
    • cargo test --target wasm32 was not run, because the wasm-bindgen test runner is not installed on this host.

Breaking changes

None. No consensus or public API change.

Checklist

  • I have performed a self-review of my own code
  • My Rust, FFI, WASM, Swift or Kotlin changes follow the coding conventions
  • I have added or updated relevant unit/integration/functional/e2e tests

Prior work

Attribution

🤖 Generated with Claude Code

https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC

PR Hygiene · 0c08eb6

  • Bots — thepastaclaw ✓
  • Self-review — not asked of a bot author
  • Build green
  • Approvals
    • files with no dedicated owner (Cargo.lock, packages/check-features/Cargo.toml, packages/rs-context-provider/Cargo.toml and 6 more) — approved by shumkov
    • rust-dapi (packages/rs-dapi/Cargo.toml, packages/rs-dapi/src/clients/tenderdash_websocket.rs) — approved by shumkov
    • dpp (packages/rs-dpp/Cargo.toml, packages/rs-dpp/src/data_contract/methods/validate_document/v2/tests.rs) — approved by shumkov
    • rs-drive-abci (packages/rs-drive-abci/Cargo.toml, packages/rs-drive-abci/src/logging/destination.rs) — approved by shumkov
    • rs-drive (packages/rs-drive/Cargo.toml, packages/rs-drive/benches/document_average_worst_case.rs, packages/rs-drive/benches/document_count_worst_case.rs and 1 more) — approved by shumkov
    • rs-platform-wallet-ffi (packages/rs-platform-wallet-ffi/Cargo.toml) — HashEngineering or ZocoLini or llbartekll or romchornyi
    • wallet-storage (packages/rs-platform-wallet-storage/Cargo.toml) — lklimek
    • rs-platform-wallet (packages/rs-platform-wallet/Cargo.toml) — HashEngineering or ZocoLini or llbartekll or romchornyi
    • rust-sdk (packages/rs-sdk/Cargo.toml) — approved by shumkov
    • system-contracts (packages/withdrawals-contract/Cargo.toml) — approved by shumkov

When every merge requirement is met, the PR Hygiene check passes. Reviewer limits do not block merging; other required GitHub checks and protections still apply.

@coderabbitai

coderabbitai Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Walkthrough

This change updates dependency versions across Rust packages. It also updates URI validation tests, adapts WebSocket subscription messages to the message input type, configures rotated log-file permissions, and changes benchmark imports.

Changes: Workspace dependency and compatibility updates

Layer / File(s) Summary
URI validation dependencies and tests
packages/rs-dpp/Cargo.toml, packages/rs-dpp/src/data_contract/methods/validate_document/v2/tests.rs
The validation-schema feature enables four ICU dependencies pinned to 2.2.0. Tests check URIs with U+0558 and ASCII hosts at protocol versions 14 and 15.
DAPI WebSocket subscription messages
packages/rs-dapi/Cargo.toml, packages/rs-dapi/src/clients/tenderdash_websocket.rs
The manifest updates tower-http, tokio-tungstenite, and serial_test. Transaction and new-block subscription messages convert serialized JSON into the WebSocket text-message input type.
Rotated log-file permissions
packages/rs-drive-abci/Cargo.toml, packages/rs-drive-abci/src/logging/destination.rs
The manifest updates dependencies, including file-rotate. Rotated log creation now uses read, create, and append options with mode 0o600. A test checks the resulting permission bits.
Other package dependency updates
packages/check-features/Cargo.toml, packages/rs-context-provider/Cargo.toml, packages/rs-dapi-client/Cargo.toml, packages/rs-drive/Cargo.toml, packages/rs-drive/benches/*, packages/rs-platform-*/Cargo.toml, packages/rs-sdk*/Cargo.toml, packages/wasm-dpp*/Cargo.toml, packages/withdrawals-contract/Cargo.toml
These manifests update dependency versions or features. Drive benchmarks import black_box from std::hint instead of Criterion.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Other

Suggested reviewers: quantumexplorer, shumkov

Merge Risk: Low · previous review f551e

This dependency refresh is largely mechanical, and no in-repo breakage was found. The one open point is that the wallet FFI crate's public handle-storage accessors now return guard types from parking_lot 0.13 instead of 0.12. Only external code that names those guard types would be affected, and none was found in this repository. This is a low-risk item for the owner to be aware of before merging.

Pre-merge checks: Passed 4

Check name Status Explanation
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Title check Passed The title "chore: update Rust dependencies" matches the main change. The raw summary shows many Cargo.toml version bumps (thiserror, lru, itertools, criterion, tower-http, and others) and the objectiv…
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Full details: Title check

Explanation

The title "chore: update Rust dependencies" matches the main change. The raw summary shows many Cargo.toml version bumps (thiserror, lru, itertools, criterion, tower-http, and others) and the objectives describe a refresh of Rust dependencies. The title is short and clear. It does not mention the ICU pin, the URI validation test, or the mechanical code changes, but the task allows this level of detail.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 2c151a3 and f551eaf.

Files ignored due to path filters: 1

  • Cargo.lock is excluded by !**/*.lock
Files selected for processing: 2

  • packages/rs-dpp/Cargo.toml
  • packages/rs-drive-abci/Cargo.toml

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

@lklimek
lklimek marked this pull request as ready for review November 16, 2026 16:12
lklimek and others added 7 commits November 16, 2026 16:16
Refresh Cargo.lock with `cargo update`. Git-pinned dependencies (GroveDB,
rust-dashcore, tenderdash-abci) and `=`-pinned crates are unchanged.

Resolves the cargo-audit advisories failing the nightly
"Security: Rust Crates" workflow:
- RUSTSEC-2026-0418 (libz-sys)
- RUSTSEC-2026-0414, RUSTSEC-2026-0433 (pulldown-cmark)
- RUSTSEC-2026-0538 (quinn-udp)
- RUSTSEC-2026-0410 (zstd-sys)

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
dash-context-provider, drive-abci, platform-encryption, platform-wallet,
platform-wallet-storage and wasm-dpp2 still required thiserror 1 while
the rest of the workspace is on 2. No source changes needed.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
- itertools 0.13 -> 0.15 (dpp, drive, drive-abci, wasm-dpp); the removed
  or reshaped APIs (Position, all_equal_value, cons_tuples) are unused
- strum 0.26 -> 0.28 (dpp); only EnumString with #[strum(default)]
  changed, which the workspace does not use
- chrono-tz 0.8 -> 0.10 (dpp, token-reward-explanations only)
- num_enum 0.5 -> 0.7 (withdrawals-contract), same as dpp
- virtue 0.0.17 -> 0.0.19 (platform-serialization-derive); additive
  impl-generics support only
- enum-map 2 -> 3, parking_lot 0.12 -> 0.13, criterion 0.5 -> 0.8 (drive);
  criterion::black_box is deprecated, use std::hint::black_box
- moka 0.12.13 -> 0.12.16 (drive); drop the removed `futures-util`
  feature, which drive never used directly
- parking_lot 0.12 -> 0.13 (platform-wallet-ffi)
- mockall 0.13 -> 0.15, metrics-exporter-prometheus 0.16 -> 0.18,
  console-subscriber 0.4 -> 0.5, file-rotate 0.7 -> 0.8 (drive-abci);
  file-rotate takes OpenOptions instead of a unix mode, so pass the same
  read/create/append flags with mode 0o600, guarded by a new test

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
- tokio-tungstenite 0.21 -> 0.30 (rs-dapi); Message::Text carries
  Utf8Bytes, so convert the outgoing subscription strings
- tower-http 0.6 -> 0.7 (rs-dapi)
- serial_test 3 -> 4 (rs-dapi, platform-wallet-storage dev-deps)

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
- lru 0.16 -> 0.19 (dash-sdk, rs-dapi-client,
  rs-sdk-trusted-context-provider)
- wasm-streams 0.5 -> 0.7 (rs-sdk-trusted-context-provider); still
  within the pinned wasm-bindgen 0.2.108
- bip39 2 -> 3 (wasm-sdk); key-wallet keeps its own bip39 and no bip39
  type crosses that boundary
- android_logger 0.14 -> 0.15 (rs-unified-sdk-jni, Android only)
- toml 0.8 -> 1 (check-features)

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
The semver-compatible lockfile refresh moved icu_* 2.2.0 -> 2.4.0, i.e.
Unicode 17 -> 18 data. url's IDNA host mapping (idna_adapter) reads it,
so `Url::from_str` started accepting hosts with code points unassigned
in Unicode 17 (e.g. U+0558). That check backs the `uri` format of both
document validators and `$schema`/`$vocabulary` on contract
registration, ungated by protocol version, so nodes on the old and new
lockfile would disagree.

Restore icu_collections, icu_locale_core, icu_normalizer(_data),
icu_properties(_data) and icu_provider to 2.2.0 (no other crate moves)
and add a test pinning the verdict at protocol versions 14 and latest.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
A newer release of these crates can change consensus results, so they
are pinned with `=` and may only move behind a protocol version:
sha2, bech32, base64, fraction, derive_more, url, ed25519-dalek and
json-patch, plus the ICU4X crates and data (Unicode 17) behind `url`
host parsing, which decide `format: "uri"` validity.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
@thepastaclaw

thepastaclaw commented Nov 16, 2026 •

Copy link
Copy Markdown
Collaborator

✅ Final review complete — no blockers (commit 0c08eb6) · triage: normal

@lklimek
lklimek force-pushed the chore/rust-deps-update-v5.2 branch from 472ad48 to 89d32c9 Compare November 16, 2026 16:17
lklimek and others added 2 commits November 16, 2026 16:21
…us pins

A pinned crate may move once tests show identical results, including a
chain replay, since replayed blocks must produce the original outcome.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
Differential probes against every newer published release found no
consensus-visible difference for sha2, bech32, base64, fraction,
derive_more, url, json-patch and ed25519-dalek, so their `=` pins added
earlier on this branch are dropped (ed25519-dalek keeps its pre-existing
pin, without the added comment). The ICU4X pins stay: ICU 2.4
(Unicode 18) changes `format: "uri"` validity, as the rs-dpp guard test
shows.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
lklimek
lklimek previously approved these changes Nov 16, 2026
@github-actions

github-actions Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Waiting for bot review — thepastaclaw not yet. Wait for the missing reviews, or a writer can post /skip-bots to proceed without them; blocking findings still need addressing.
Full checklist in the description.

@github-actions github-actions Bot added the waiting-bots Waiting for the review bots to report on this head label Nov 16, 2026
@lklimek
lklimek changed the base branch from v5.2-dev to v5.1-dev November 16, 2026 16:42
@lklimek
lklimek dismissed their stale review November 16, 2026 16:42

The base branch was changed.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Additional comments: 1

packages/rs-platform-wallet-ffi/Cargo.toml-28-28: 1

28-28: Minor · Data Integrity & Integration · Quick win

Unverified finding
Verification ran but could not confirm this finding. It is shown for review, not as a verified issue.

Preserve the public guard types.

A Rust caller that expects a parking_lot 0.12 guard from HandleStorage::get or get_mut will no longer compile. These methods are public, and the crate builds an rlib. (raw.githubusercontent.com) The 0.13 upgrade changes the guard types, including their lock_api dependency. (github.com) Keep 0.12 here to preserve the stated public API.

Review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 28c5c14 and 2c151a3.

Files ignored due to path filters: 1

  • Cargo.lock is excluded by !**/*.lock
Files selected for processing: 25

  • packages/check-features/Cargo.toml
  • packages/rs-context-provider/Cargo.toml
  • packages/rs-dapi-client/Cargo.toml
  • packages/rs-dapi/Cargo.toml
  • packages/rs-dapi/src/clients/tenderdash_websocket.rs
  • packages/rs-dpp/Cargo.toml
  • packages/rs-dpp/src/data_contract/methods/validate_document/v2/tests.rs
  • packages/rs-drive-abci/Cargo.toml
  • packages/rs-drive-abci/src/logging/destination.rs
  • packages/rs-drive/Cargo.toml
  • packages/rs-drive/benches/document_average_worst_case.rs
  • packages/rs-drive/benches/document_count_worst_case.rs
  • packages/rs-drive/benches/document_sum_worst_case.rs
  • packages/rs-platform-encryption/Cargo.toml
  • packages/rs-platform-serialization-derive/Cargo.toml
  • packages/rs-platform-wallet-ffi/Cargo.toml
  • packages/rs-platform-wallet-storage/Cargo.toml
  • packages/rs-platform-wallet/Cargo.toml
  • packages/rs-sdk-trusted-context-provider/Cargo.toml
  • packages/rs-sdk/Cargo.toml
  • packages/rs-unified-sdk-jni/Cargo.toml
  • packages/wasm-dpp/Cargo.toml
  • packages/wasm-dpp2/Cargo.toml
  • packages/wasm-sdk/Cargo.toml
  • packages/withdrawals-contract/Cargo.toml

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

…pdate-v5.2

Conflicts in Cargo.lock and packages/rs-drive-abci/Cargo.toml resolved
by keeping this branch's crates.io versions and v5.1-dev's git
dependencies (Tenderdash 2.0.0-dev.2, GroveDB 89dc7351, rust-dashcore
f6bb90cb, dashcore-crypto replacing bls-signatures). ICU stays at 2.2.0.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
@github-actions

github-actions Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Waiting for bot review — thepastaclaw not yet. Wait for the missing reviews, or a writer can post /skip-bots to proceed without them; blocking findings still need addressing.
Full checklist in the description.

lklimek
lklimek previously approved these changes Nov 16, 2026

@thepastaclaw thepastaclaw left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Final validation — Phase 1 + Phase 2

The refresh introduces two blocking compatibility risks in production cryptographic and wallet derivation paths. The lockfile updates shielded proof dependencies without compatibility evidence, and the WASM SDK now resolves Unicode normalization data that can derive different BIP39 seeds for existing passphrases. Three additional in-scope test/constraint gaps should be addressed; Rust workspace tests remain pending, while wasm32 and image checks shown in the snapshot have passed.

🔴 2 blocking | 🟡 3 suggestion(s)

2 finding(s) not shown inline (the lines are not part of this PR's diff)

🔴 Blocking: Shielded consensus dependencies change without a compatibility guard
Cargo.lock:3535-3548

This refresh changes halo2_proofs from 0.3.2 to 0.3.5 and also moves the production Orchard dependency graph from bitvec 1.0.1 to 1.1.1, blake2b_simd 1.0.4 to 1.0.5, and pasta_curves 0.5.1 to 0.5.2. The pinned GroveDB grovedb-commitment-tree package depends on Orchard, while rs-drive-abci uses that tree for shielded state-transition validation and rs-dpp uses it in shielded transaction construction. These libraries participate in proof verification, field arithmetic, commitment roots, and serialized shielded values. Halo2 0.3.1 already documents a proof-verification acceptance change, so a semver-compatible lockfile update cannot be treated as tooling-only. No protocol boundary or differential proof/root/serialization evidence accompanies this change, despite the PR claiming network-visible behavior remains identical. Retain the prior exact versions or add deterministic old/new compatibility vectors and explicitly account for any intended proof-acceptance change before merging.

source: gpt-6.1-sol (phase2-reviewer: architecture-layering)

🟡 Suggestion: Compile the Android logger call site for the dependency upgrade
packages/rs-unified-sdk-jni/src/lib.rs:49-54

The upgraded android_logger dependency is used only inside cfg(target_os = "android"), so the Linux workspace checks and the reported Kotlin build do not compile this call site. Manually confirming that init_once, Config, with_max_level, and with_tag exist does not verify the target-specific type signatures or configuration behavior. Add an Android-target cargo check to the relevant CI coverage, or provide an existing Android Rust build job that is guaranteed to compile this crate.

source: muse-spark-1.3-contributor (phase1-reviewer: general, rust-quality)

Review provenance

Source: reviewer 1: muse-spark-1.3-contributor (agent: phase1-reviewer, role: general); reviewer 2: muse-spark-1.3-contributor (agent: phase1-reviewer, role: rust-quality); reviewer 3: gpt-6.1-sol (agent: phase2-reviewer, role: general); reviewer 4: gpt-6.1-sol (agent: phase2-reviewer, role: architecture-layering); reviewer 5: gpt-6.1-sol (agent: phase2-reviewer, role: platform-versioning); reviewer 6: gpt-6.1-sol (agent: phase2-reviewer, role: rust-quality); reviewer 7: gpt-6.1-sol (agent: phase2-reviewer, role: security-auditor); reviewer 8: gpt-6.1-sol (agent: phase2-reviewer, role: general); reviewer 9: gpt-6.1-sol (agent: phase2-reviewer, role: architecture-layering); reviewer 10: gpt-6.1-sol (agent: phase2-reviewer, role: platform-versioning); reviewer 11: gpt-6.1-sol (agent: phase2-reviewer, role: rust-quality); reviewer 12: gpt-6.1-sol (agent: phase2-reviewer, role: security-auditor); final verifier: gpt-6.1-sol (agent: sol-verifier, role: final-verifier)

  • Triage: normal by gpt-6.1-sol (effort low) — This is a broad Rust dependency refresh with consensus-sensitive dependency pinning and mechanical source changes, but the diff does not directly alter consensus logic, funds movement, cryptography, or another critical surface under the stated criteria.
  • Phase 1 reviewers: muse-spark-1.3-contributor — general (completed, effort xhigh); agent phase1-reviewer, muse-spark-1.3-contributor — rust-quality (completed, effort xhigh); agent phase1-reviewer
  • Phase 1 model: muse-spark-1.3-contributor — not quota-gated; passed over gemini-3.8-flash-high (antigravity quota lookup failed), glm-5.3-flash (not used above high effort; tier asks max)
  • Second Phase-2 pass: on this first full review every Phase-2 reviewer also ran a second, independent time, and the verifier weighed both sets
  • Fresh verifier: gpt-6.1-sol — final-verifier; agent sol-verifier
  • Phase 2 reviewers: gpt-6.1-sol — general (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — architecture-layering (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — platform-versioning (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — rust-quality (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — security-auditor (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — general (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — architecture-layering (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — platform-versioning (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — rust-quality (completed, effort high); agent phase2-reviewer, gpt-6.1-sol — security-auditor (completed, effort high); agent phase2-reviewer
🤖 Prompt for all review comments with AI agents
These findings are from an automated code review (PastaClaw). How to work through them:
- Verify each finding against the code; fix only what is real, as narrowly as the finding.
- If a finding is wrong, decline it on its thread in one or two sentences; the bot answers once and stops.
- To defer one, link a tracking issue on its thread (or reply asking the bot to file one).
- Suggestions don't block the merge, but most are worth fixing in this PR; judge each on its merits.
- Keep the PR's scope; don't grow it to satisfy hardening suggestions.
- Carried items were raised in an earlier round: read the thread first, and don't re-fix what you already fixed, declined or deferred there. Disputed and deferred items are already handled and are not listed.

In `Cargo.lock`:
- [BLOCKING] Cargo.lock:3535-3548: Shielded consensus dependencies change without a compatibility guard
  This refresh changes `halo2_proofs` from 0.3.2 to 0.3.5 and also moves the production Orchard dependency graph from `bitvec` 1.0.1 to 1.1.1, `blake2b_simd` 1.0.4 to 1.0.5, and `pasta_curves` 0.5.1 to 0.5.2. The pinned GroveDB `grovedb-commitment-tree` package depends on Orchard, while `rs-drive-abci` uses that tree for shielded state-transition validation and `rs-dpp` uses it in shielded transaction construction. These libraries participate in proof verification, field arithmetic, commitment roots, and serialized shielded values. Halo2 0.3.1 already documents a proof-verification acceptance change, so a semver-compatible lockfile update cannot be treated as tooling-only. No protocol boundary or differential proof/root/serialization evidence accompanies this change, despite the PR claiming network-visible behavior remains identical. Retain the prior exact versions or add deterministic old/new compatibility vectors and explicitly account for any intended proof-acceptance change before merging.

In `packages/wasm-sdk/Cargo.toml`:
- [BLOCKING] packages/wasm-sdk/Cargo.toml:108: Preserve BIP39 passphrase normalization for existing wallets
  Changing the WASM SDK to `bip39` 3.0 resolves `unicode-normalization` from 0.1.25 (Unicode 17 data) to 0.1.26 (Unicode 18 data). The newer table adds mappings such as U+0558 to U+0567, while the older table leaves U+0558 unchanged. `mnemonicToSeed` passes the caller's arbitrary passphrase directly to `Mnemonic::to_seed` at `packages/wasm-sdk/src/wallet/key_derivation.rs:377-390`, where BIP39 applies NFKD before PBKDF2. Therefore an existing wallet using an affected passphrase derives different seed bytes after this update and can appear to restore as a different wallet. The same normalization package is also selected for the pinned key-wallet dependency. Keep the normalization data at the deployed version for wallet derivation, or introduce an explicit compatibility generation with regression vectors covering mnemonic-plus-passphrase pairs containing newly assigned Unicode code points.

In `packages/rs-dpp/Cargo.toml`:
- [SUGGESTION] packages/rs-dpp/Cargo.toml:72-76: The ICU pin does not freeze the complete behavior dependency graph
  The four exact ICU pins constrain the normalizer and property data packages, but their manifests still allow supporting packages such as `icu_provider`, `icu_locale_core`, `zerovec`, `litemap`, and related crates to move within their compatible ranges. The current lockfile resolves those packages to 2.2.0, but a later lockfile refresh can change them without changing any of the four exact pins. Since these packages implement data-provider and normalization support behavior used by the URL/IDNA path, the manifest does not fully establish the stated consensus freeze. Pin the complete relevant ICU closure, or document why each remaining floating package cannot affect the URI verdict and extend the guard if needed.

In `packages/rs-dpp/src/data_contract/methods/validate_document/v2/tests.rs`:
- [SUGGESTION] packages/rs-dpp/src/data_contract/methods/validate_document/v2/tests.rs:610-623: Add a regression test for schema metadata URI validation
  The added guard exercises only a document property with `format: "uri"`. Contract schema registration separately validates `$schema` and each `$vocabulary` key with `Url::parse` in `packages/rs-dpp/src/data_contract/document_type/schema/validation_schema/v0/mod.rs:539-546`. The PR description identifies those metadata URLs as another consensus-sensitive surface, but a future URL/ICU change could alter their registration verdict without affecting the new document-value test. Add registration tests using the same Unicode edge case for `$schema` and `$vocabulary`.

In `packages/rs-unified-sdk-jni/src/lib.rs`:
- [SUGGESTION] packages/rs-unified-sdk-jni/src/lib.rs:49-54: Compile the Android logger call site for the dependency upgrade
  The upgraded `android_logger` dependency is used only inside `cfg(target_os = "android")`, so the Linux workspace checks and the reported Kotlin build do not compile this call site. Manually confirming that `init_once`, `Config`, `with_max_level`, and `with_tag` exist does not verify the target-specific type signatures or configuration behavior. Add an Android-target `cargo check` to the relevant CI coverage, or provide an existing Android Rust build job that is guaranteed to compile this crate.
Out-of-scope follow-up suggestions (1)

These are valid observations, but they are outside this PR's scope and should be handled in separate issues or author/maintainer-requested PRs rather than blocking this review.

  • Compressed rotated logs may not retain owner-only permissions — The new OpenOptions test verifies only the active log file. The file-rotate compression path can create .gz archives with default permissions, so compressed rotated logs may be readable by other local users even though the active file is 0o600. This behavior predates the reviewed range and is not introduced by the dependency refresh.
    • Follow-up: Track this in a separate logging-security issue or follow-up PR that enforces 0o600 on compressed archives and tests a rotation that produces a .gz file.

Comment thread packages/wasm-sdk/Cargo.toml Resolved
Comment thread packages/rs-dpp/Cargo.toml Resolved
@github-actions github-actions Bot added waiting-self-review Waiting for the author to post /self-reviewed and removed waiting-bots Waiting for the review bots to report on this head labels Nov 16, 2026
lklimek and others added 2 commits November 16, 2026 19:21
…eview or tests object

- Keep halo2_proofs 0.3.2, bitvec 1.0.1, blake2b_simd 1.0.4 and
  pasta_curves 0.5.1: they sit under Orchard proof verification and need
  compatibility evidence before a bump.
- Keep bip39 2 in wasm-sdk and unicode-normalization 0.1.25: NFKD of a
  BIP39 passphrase must not change for existing wallets.
- Keep android_logger 0.14: no Android Rust build covers it here.
- Use tokio 1.53.3: 1.54.1 deadlocks platform-wallet's
  should_not_take_the_store_as_read_by_a_pass_a_sender_was_unignored_under.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYijwZNbw3EjHtdMAHC
@github-actions github-actions Bot added this to the v5.1.0 milestone Nov 16, 2026
@lklimek lklimek changed the title chore(deps): update Rust dependencies chore: update Rust dependencies Nov 16, 2026
lklimek
lklimek previously approved these changes Nov 16, 2026
@lklimek
lklimek changed the base branch from v5.1-dev to v5.2-dev November 17, 2026 05:35
@lklimek
lklimek dismissed their stale review November 17, 2026 05:35

The base branch was changed.

@github-actions github-actions Bot modified the milestones: v5.1.0, v5.2.0 Nov 17, 2026
@Claudius-Maginificent
Claudius-Maginificent changed the base branch from v5.2-dev to chore/merge-v5.1-dev-into-v5.2-dev November 17, 2026 05:39
@github-actions github-actions Bot removed the ready-for-human Bots have reported, the author has self-reviewed, and the build is green: this needs a human. label Nov 17, 2026
lklimek
lklimek previously approved these changes Nov 17, 2026
Base automatically changed from chore/merge-v5.1-dev-into-v5.2-dev to v5.2-dev November 17, 2026 12:33
@shumkov
shumkov dismissed lklimek’s stale review November 17, 2026 12:33

The base branch was changed.

@github-actions

github-actions Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

Ready for review — rs-platform-wallet-ffi: HashEngineering or ZocoLini or llbartekll or romchornyi · wallet-storage: lklimek · rs-platform-wallet: HashEngineering or ZocoLini or llbartekll or romchornyi.
Full checklist in the description.

@github-actions github-actions Bot added the ready-for-human Bots have reported, the author has self-reviewed, and the build is green: this needs a human. label Nov 17, 2026
@github-actions
github-actions Bot requested a review from lklimek November 17, 2026 12:34
@lklimek
lklimek merged commit f5195d3 into v5.2-dev Nov 17, 2026
103 of 106 checks passed
@lklimek
lklimek deleted the chore/rust-deps-update-v5.2 branch November 17, 2026 14:47
lklimek added a commit to dashpay/dash-evo-tool that referenced this pull request Nov 20, 2026
Repin every dashpay/platform git dependency to the head of
dashpay/platform#5948 (Rust dependency refresh on v5.1-dev).

- rusqlite 0.41.1 and refinery =0.10.0 so DET links one libsqlite3-sys
  0.39.1, fixing RUSTSEC-2026-0459; the lru advisory RUSTSEC-2026-0253
  is gone too. Refinery 0.10 computes migration checksums exactly as
  0.9.2 did.
- icu_properties 2.2.0 to match dpp's consensus pin; clap gains the
  `env` feature det-cli relied on through feature unification.
- Adapt to upstream API changes: dash-spv re-exports, base58 decode via
  platform_value, HMAC engines, `Sdk::set_context_provider` returning
  Result, new struct fields and PlatformWalletError variants, and the
  paged contested-DPNS vote-state query.
- Platform compatibility bridge: upstream adds migration V020 (nullable
  `asset_locks.shielded_recipient` plus an immutability trigger). The
  destination guard moves from fixtures/033ecae.sql to
  fixtures/0c08eb6.sql, which equals an empty database created by the
  real runner at 0c08eb6c; the bridge leaves the new column NULL.

The platform pin guard fails ancestry until #5948 lands on v5.1-dev.
The migration fingerprint moved only because V020 was added and needs
a human `check-pin-ancestry.sh --update` after that.

BREAKING CHANGE: wallet storage upgrades to V020; older builds cannot
open the upgraded store.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>


Claude-Session: https://claude.ai/code/session_01WunYYgEM1sCajUbDqbHmaK

Co-authored-by: Lukasz Klimek <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
lklimek added a commit to dashpay/dash-evo-tool that referenced this pull request Nov 20, 2026
* chore(deps): bump dashpay/platform to 0c08eb6c (#5948)

Repin every dashpay/platform git dependency to the head of
dashpay/platform#5948 (Rust dependency refresh on v5.1-dev).

- rusqlite 0.41.1 and refinery =0.10.0 so DET links one libsqlite3-sys
  0.39.1, fixing RUSTSEC-2026-0459; the lru advisory RUSTSEC-2026-0253
  is gone too. Refinery 0.10 computes migration checksums exactly as
  0.9.2 did.
- icu_properties 2.2.0 to match dpp's consensus pin; clap gains the
  `env` feature det-cli relied on through feature unification.
- Adapt to upstream API changes: dash-spv re-exports, base58 decode via
  platform_value, HMAC engines, `Sdk::set_context_provider` returning
  Result, new struct fields and PlatformWalletError variants, and the
  paged contested-DPNS vote-state query.
- Platform compatibility bridge: upstream adds migration V020 (nullable
  `asset_locks.shielded_recipient` plus an immutability trigger). The
  destination guard moves from fixtures/033ecae.sql to
  fixtures/0c08eb6.sql, which equals an empty database created by the
  real runner at 0c08eb6c; the bridge leaves the new column NULL.

The platform pin guard fails ancestry until #5948 lands on v5.1-dev.
The migration fingerprint moved only because V020 was added and needs
a human `check-pin-ancestry.sh --update` after that.

BREAKING CHANGE: wallet storage upgrades to V020; older builds cannot
open the upgraded store.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYgEM1sCajUbDqbHmaK

* test(dashpay): pin calculate_account_reference to a golden value

DIP-15 publishes no account-reference vector, so pin DET's output for
inputs taken from DIP-14 Test Vector 1 (its published seed and final
private key). The values were computed with the previous HMAC API on
v1.0-dev 1cae75d and match after the rust-dashcore HMAC migration.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* build: optimize dash-pow and wide in debug and test builds

dash-spv now hashes every header of a headers2 message with X11 inline
on its async reader task, and X11 comes from pure-Rust dash-pow on
`wide` SIMD, which is very slow at opt-level 0. In debug and test
builds those hashes held tokio workers for seconds, the request-timeout
monitor starved and kicked healthy peers, and SPV sync from genesis
stalled; the migration matrix's network step missed its 600 s gate.
With these two crates at opt-level 3, as argon2 already is, the
v1.0.0-weekly.20260908 fixture syncs and derives its address again.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* build: optimize dashcore and bitcoin-internals in debug and test builds (#1189)

SPV sync on rust-dashcore d85f15ac runs filter matching (SipHash, emitted
in dashcore) and the per-header Dark Gravity Wave check (U256 arithmetic
in bitcoin-internals) on the tokio workers. Unoptimized, a debug testnet
sync took 524-550 s; with both crates at opt-level 3 it takes 115-122 s.
Measured in dashpay/rust-dashcore#1425.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>


Claude-Session: https://claude.ai/code/session_01WunYYgEM1sCajUbDqbHmaK

Co-authored-by: Lukasz Klimek <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>

* fix: drop an import the v1.0-dev merge left unused

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYgEM1sCajUbDqbHmaK

* chore(deps)!: pin platform to v5.2-dev merge of #5948

Pin all four Platform dependencies to f5195d311cf1dd5f6d30a423aecfd09f2462d9df
and refresh the ancestry target and migration fingerprint.

Copy legacy data into the V020 stage before running upstream V021 accounting
backfill, verify its final schema, and publish it atomically. Box the enlarged
typed storage errors and adapt their constructors and matches.

Cover historical and V020 upgrades, original record retention, accounting
repair, stable sync state, and refusal of invalid historical transactions.

BREAKING CHANGE: Wallet storage advances to upstream V021 transaction accounting.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: OpenAI Codex <[email protected]>

* chore(deps): pin platform to the v5.2-dev tip 2651f7e2

Moves every dashpay/platform dependency from f5195d31 (the merge of
platform#5948) to 2651f7e2, the current tip of v5.2-dev. The three commits in
between are platform#5965 (dev-profile optimization, which Cargo does not
apply to dependents), #5613 (token balances of wallet-owned identities are
persisted) and #5683 (an identity update fetches the identity first).

The wallet-storage migrations are identical at both revisions (21 files,
same fingerprint), so only the recorded pin changes in the pin guard.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* build: pin icu_properties to the exact version dpp uses

dpp pins icu_properties to =2.2.0 for consensus. DET's own requirement was
a caret one, so a later lockfile refresh could have given DET's alias
cleaning newer Unicode data than dpp normalizes with.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* test(migration): expect the input row V021 derives in the real weekly profile

Platform's V021 indexes the inputs of every stored transaction. The upgrade
of the real v1.0.0-weekly.20260908 profile therefore fills
core_transaction_inputs with one row for the captured faucet payment, and
the test's "tables the upgrade created must start empty" check failed in the
migration suite.

The test now states the rows each database's upgrade derives and requires
exactly those: one input row for the network store, none for the app store,
and nothing in any other new table.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(shielded): stop advising a retry when a shielded funding resume is refused

Upstream refuses to resume a shielded funding to another address than the
one its asset lock recorded, pays nobody, and refuses the same request every
time. That error took the generic wallet envelope, whose message tells the
user to retry.

It now maps to TaskError::ShieldedFundingRecipientMismatch, which says that
nothing was sent and which address to use. The identity and address-funding
classifier keeps it in the generic bucket: none of those flows resumes a
shielded funding.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(dpns): read every page of a contest's contenders

The contender refresh sent one vote-state query without a limit. A proved
answer holds at most 100 contenders, so a contest with more lost the rest.

It now uses Sdk::fetch_contested_resource_vote_state, which reads every page
and keeps the tallies and winner of the first one.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(wallet): explain asset-lock input limit refusals

Preserve upstream counts and the typed source across identity, address,
shielded, direct funding, and foreign-identity resume error mappings.
Advise checking the previous transfer before starting a smaller one.

Cover all six mappings and update the upstream cap documentation.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: OpenAI Codex <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYgEM1sCajUbDqbHmaK

* test(dpns): verify refresh persists paginated contenders

Mock a full first page and a distinct second-page contender with a
serialized domain document. Assert the refresh stores that contender
and preserves the first page tallies.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: OpenAI Codex <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYgEM1sCajUbDqbHmaK

* fix(sdk): tell the user to check first when a submitted request's result is unknown

The SDK now reports a broadcast whose result could not be read as
`StateTransitionResultUnconfirmed`, also wrapped in
`NoAvailableAddressesToRetry` when retries ran out. `From<SdkError>` knew
only the older cause-less `StateTransitionBroadcastError`, so these became
"An unexpected error occurred. Please try again later." or the servers
unreachable message. A credit transfer retried on that advice is built anew
with a fresh nonce and can pay the recipient twice.

Both shapes now map to `PlatformResultUnconfirmed`, with the SDK error kept
as the source, before any mapping that advises a retry. A test pins that the
availability reclassification leaves it alone.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(wallet): treat funds awaiting confirmation as a known asset-lock outcome

The pinned builder returns `FundsAwaitingFinality` when final coins cannot
fund an asset lock but coins that are not confirmed or InstantSend locked
yet could. DET's probes knew only the old shortfall, so:

- a wallet whose only coin was still unconfirmed got "The wallet's available
  amount could not be checked" instead of a Max of zero;
- a Max search probing such an amount aborted;
- the check before the unlock prompt let the amount through, so the user was
  asked for a password before the build refused.

The drain now reports nothing to drain, the search treats the amount as
unbuildable, and the pre-unlock check refuses with
`AssetLockFundsAwaitingConfirmation`, which names the amount still waiting.
Upstream's own `AssetLockFundsAwaitingFinality` maps to the same error in
every asset-lock mapper instead of the generic "retry in a moment".

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* test: say why the mock SDK accepts the SPV context provider

The `expect` claimed the provider serves the mock SDK's network. It declares
no network, which is why the SDK accepts it whatever network the mock uses.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(contract): check private document entry sizes before signing a contract update

Platform registers a private document type whose entries are too small for
its largest document, and the entry size can never change afterwards. The SDK
refuses such a type on contract creation, but DET builds the update
transition itself and skipped the check, so a paid update could leave a type
that cannot store its own documents.

The update now runs `ensure_private_document_entries_fit_on_update` before
the nonce is read or the contract is changed. It reads the stored contract
only when the update declares a private type and leaves unchanged types
alone.

Both refusals the check can return get their own error, for creation and
update alike, naming the type and what to change. They used to read "An
unexpected error occurred. Please try again later."

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(wallet): say the pending funds would be used, not that they are needed

`waiting` is the total value of the unconfirmed coins the build would spend,
not the requested amount or the shortfall. A request for 0.005 DASH that
would spend a pending 0.01 DASH coin read as if 0.01 DASH were needed.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* test(spv): assert the peer count a peer-list update publishes

The test sent an empty list to a status already at zero peers and checked
only the repaint, so it passed even if the bridge stopped publishing the
count.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(sdk): recognise the readiness error the SDK returns before masternodes sync

Before the masternode list has synced, DET's context provider answers a
quorum key request with a `Config` error. The proof verifier wraps it in
`QuorumKeyUnavailable`, and since platform#5769 the SDK's conversion lifts a
provider `Config` failure out of the proof error into a top-level
`ContextProviderError`, which it neither retries nor bans a node for.

DET matched only `Proof(ContextProviderError(Config))`, a shape a request no
longer returns, so a proved read that reached the provider before sync was
reported as a generic SDK failure instead of `MasternodeListNotReady`, and
lost the banner that clears when sync catches up. The two tests built that
shape by hand, so they kept passing; one of them pinned a node ban the SDK
no longer applies.

The matcher now reads the provider error from the top-level variant and
from both verifier shapes, and still requires the provider's own readiness
text. The tests go through the SDK's conversion: the readiness wait is
reported, no node is banned, and another provider configuration failure is
not treated as a startup wait.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(contract): give the right advice when a registered private type is outgrown

The entry-size refusal told the user to raise the entry size. Platform locks
a private document type's entry size once the type is registered, so for an
update that grows a registered type that advice leads to a second refusal.

The refusal does not say whether the type is new, so the message now gives
both remedies: a larger entry size for a new type, and smaller or fewer
added fields, or a new type, for a registered one. The update test asserts
the second.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(wallet): label a history row by the wallet's direction, not the amount's sign

The history row kept a transaction's signed amount and dropped the
direction the wallet classified it with, and the table derived "Received",
"Sent" or "Internal" from the sign. Platform's wallet-level accounting
classifies a move into the wallet's own Platform keys, or between its own
accounts, as Internal while the Core balance goes down by the locked amount
or the fee, so such a row read "Sent", as if it were a payment to someone
else.

The row now carries the upstream direction and the label comes from it. The
amount keeps its sign and colour. A mixing transaction has no label of its
own and keeps the one its amount gives, as before.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(sdk): say to change a request the SDK refuses as invalid

`SdkError::InvalidRequest` is the SDK's answer for a request that has to
change, such as a document query no index covers: every node answers it
alike and it is not retried. DET showed "An unexpected error occurred.
Please try again later." It now maps to `PlatformRequestInvalid`, which says
that waiting will not help and to change the request, with the SDK's refusal
kept as the source.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* test(ui): use the non-deprecated egui id constructor in the token sub-navigation test

The base branch gained this test (#1169) and the egui 0.37 bump (#1184)
separately. egui 0.37 deprecates `Id::new`, so clippy with `-D warnings`
fails on the merged tree. `Id::new` is an alias of `Id::unique`, so the
panel id the test looks up is unchanged.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(shielded): classify SDK errors from shielded operations like every other path

Shielding from Core broadcasts through the SDK, and at the new Platform pin
a result that could not be read after the broadcast comes back as
`StateTransitionResultUnconfirmed` inside `PlatformWalletError::Sdk`.
`map_shielded_op_error` filed every SDK error under the generic wallet
envelope, whose message says to retry. A retried shield from Core builds a
new funding lock, so it could shield the amount and pay the fee twice.

The mapper now sends an SDK error through `TaskError::from`, as the
register, top-up and address-funding mappers already do, so the user is told
to check whether the request completed first. An SDK error the classifier
has no dedicated answer for keeps the generic envelope it had before.

A table test runs both shapes of the unconfirmed result (direct, and wrapped
after every server was tried) through all four wallet mappers.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* fix(wallet): say to check after an ambiguous lock resume, and keep the source of a pending-funds refusal

Two follow-ups from review:

- Resuming a tracked asset lock can come back as
  `TransactionBroadcastUnconfirmed`: its transaction may already be on the
  network. `map_asset_lock_error` filed that under the generic wallet
  envelope, which says to retry. It now maps to
  `TransactionConfirmationUnknown`, as every other funding path does, and
  the mapper joins the test that pins this for all of them.
- `AssetLockFundsAwaitingConfirmation` kept only the waiting amount and
  dropped the wallet's refusal. It now carries it as its source wherever a
  build or resume reported it; the check made before the unlock prompt has
  no wallet error and carries none.

Co-Authored-By: Claude Fable 5.2 <[email protected]>

* refactor(wallet): classify asset-lock refusals in one place

The input-limit and pending-finality refusals were mapped separately by the
asset-lock, shielded, identity register, identity top-up and platform-address
funding mappers. Route all five through `map_asset_lock_refusal_or` and drop
the now-redundant `IdentityOpErrorKind` buckets. No behaviour change.

<sub>🤖 Co-authored by [Claudius the Magnificent](https://github.com/lklimek/claudius) AI Agent</sub>

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01WunYYk4eUkHuGstPtj83j4

---------

Co-authored-by: Lukasz Klimek <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
Co-authored-by: OpenAI Codex <[email protected]>
Co-authored-by: Quantum Explorer <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-human Bots have reported, the author has self-reviewed, and the build is green: this needs a human.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants