Skip to content

Conversation

@sahar-fehri
Copy link
Contributor

@sahar-fehri sahar-fehri commented Dec 9, 2025

Explanation

PR fixes wrong rates for non-evm chains.

References

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

Note

MultichainAssetsRatesController now fetches accountsAssets from state on demand instead of caching, fixing stale rates; adds targeted tests and updates changelog.

  • Assets Controllers:
    • MultichainAssetsRatesController
      • Remove cached #accountsAssets; #getAssetsForAccount now calls MultichainAssetsController:getState each time to get fresh accountsAssets.
      • Minor typing/return annotations and async-safe event subscriptions.
  • Tests:
    • Add "dynamic asset fetching" test ensuring rates are fetched for assets added post‑init.
    • Adjust setupController to return typed helpers; import CaipAssetType.
  • Changelog:
    • Document fix for stale accountsAssets causing incorrect non‑EVM conversion rates when currency changes.

Written by Cursor Bugbot for commit 68e2c6c. This will update automatically on new commits. Configure here.

@sahar-fehri sahar-fehri changed the title fix: fix stale reference for assets state fix: fix stale reference for multichain assets state Dec 9, 2025
@sahar-fehri sahar-fehri marked this pull request as ready for review December 10, 2025 00:15
@sahar-fehri sahar-fehri requested review from a team as code owners December 10, 2025 00:15
@sahar-fehri sahar-fehri added this pull request to the merge queue Dec 10, 2025
Merged via the queue into main with commit 60229aa Dec 10, 2025
283 checks passed
@sahar-fehri sahar-fehri deleted the fix/fix-stale-reference-multichain-assets-rates-controller branch December 10, 2025 16:53
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.

3 participants