Skip to content

Conversation

@cryptodev-2s
Copy link
Contributor

@cryptodev-2s cryptodev-2s commented Jun 11, 2024

Explanation

In this PR, the AccountTrackerController has been updated to BaseControllerV2. The upgrade involves the AccountTrackerController now inheriting from StaticIntervalPollingController instead of StaticIntervalPollingControllerV1. This change affects the constructor by removing deprecated config properties, keeping only the interval option as a constructor parameter. Additionally, the provider property has been removed, as it is now directly retrieved by actions from NetworkState.

References

Fixes #4071

Changelog

@metamask/assets-controller

Added

  • New types for AccountTrackerController messenger actions
    • AccountTrackerControllerGetStateAction
  • New types for AccountTrackerController messenger events
    • AccountTrackerControllerStateChangeEvent

Changed

  • BREAKING: Changed superclass of AccountTrackerController from StaticIntervalPollingControllerV1 to StaticIntervalPollingController
  • BREAKING: Renamed AccountTrackerState to AccountTrackerControllerState

Removed

  • BREAKING: Removed AccountTrackerConfig type

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 highlighted breaking changes using the "BREAKING" category above as appropriate

@cryptodev-2s cryptodev-2s added the team-wallet-framework Deprecated: Please use `team-core-platform` instead. label Jun 11, 2024
@cryptodev-2s cryptodev-2s requested review from a team June 11, 2024 14:29
@cryptodev-2s cryptodev-2s requested review from kanthesha and mcmire June 11, 2024 22:26
@cryptodev-2s cryptodev-2s requested a review from kanthesha June 13, 2024 10:22
@cryptodev-2s cryptodev-2s requested a review from kanthesha June 13, 2024 15:10
Copy link
Contributor

@kanthesha kanthesha left a comment

Choose a reason for hiding this comment

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

LGTM.

@cryptodev-2s cryptodev-2s merged commit 6982c7f into main Jun 13, 2024
@cryptodev-2s cryptodev-2s deleted the feature/upgrade-account-tracker-controller-to-base-controller-v2 branch June 13, 2024 17:09
@montelaidev montelaidev mentioned this pull request Jun 25, 2024
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

team-wallet-framework Deprecated: Please use `team-core-platform` instead.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert AccountTrackerController from BaseControllerV1 to BaseControllerV2

4 participants