Skip to content

Conversation

@mikesposito
Copy link
Member

@mikesposito mikesposito commented Sep 29, 2025

Explanation

This PR migrates all remaining assets controllers to @metamask/messenger instead of @metamask/base-controller. This is part of a larger effort to migrate all controllers to use @metamask/messenger.

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, highlighting breaking changes as necessary
  • I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes

Note

Migrates remaining assets controllers and tests from base-controller RestrictedMessenger to @metamask/messenger, updating metadata flags and event wiring.

  • Controllers (migration to @metamask/messenger):
    • MultichainAssetsController, MultichainBalancesController, NftDetectionController, RatesController, TokenSearchDiscoveryDataController now use Messenger types and this.messenger for call/subscribe/publish (replacing RestrictedMessenger/messagingSystem).
    • Update controller-specific messenger types and allowed actions/events; add namespaced messengers in tests via delegate.
  • Metadata updates:
    • Switch to @metamask/base-controller/next and StateMetadata; replace anonymous with includeInDebugSnapshot where applicable.
  • Tests:
    • Refactor to root messenger + delegated namespaced messengers; update imports to /next; adjust assertions to new metadata flags; minor test helpers tweaks.
  • RatesController:
    • Maintain polling events via this.messenger.publish and expose metadata via StateMetadata.
  • Changelog:
    • Consolidate BREAKING note: controllers migrated to new Messenger API.

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

mikesposito and others added 18 commits October 23, 2025 16:06
…ontroller' into mikesposito/messenger/polling-controllers

* origin/mikesposito/messenger/approval-controller:
  Update changelogs following branch update
  Update messagingSystem references to messenger
…ntrollers' into mikesposito/messenger/assets-controllers

* origin/mikesposito/messenger/polling-controllers:
  Update ESLint warning threshold
  Fix changelog mistakes from recent merges
  Update changelogs following branch update
  Update messagingSystem references to messenger
cryptodev-2s
cryptodev-2s previously approved these changes Oct 26, 2025
Copy link
Contributor

@cryptodev-2s cryptodev-2s left a comment

Choose a reason for hiding this comment

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

LGTM!

Base automatically changed from mikesposito/messenger/polling-controllers to main October 27, 2025 12:54
@mikesposito mikesposito dismissed cryptodev-2s’s stale review October 27, 2025 12:54

The base branch was changed.

@mikesposito mikesposito added this pull request to the merge queue Oct 27, 2025
Merged via the queue into main with commit 08302be Oct 27, 2025
254 of 255 checks passed
@mikesposito mikesposito deleted the mikesposito/messenger/assets-controllers branch October 27, 2025 13:16
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.

5 participants