-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: account tracker controller with useMultiPolling #28277
Open
sahar-fehri
wants to merge
16
commits into
develop
Choose a base branch
from
feat/multi-chain-for-account-tracker-controller-v2
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
fix: account tracker controller with useMultiPolling #28277
sahar-fehri
wants to merge
16
commits into
develop
from
feat/multi-chain-for-account-tracker-controller-v2
+286
−65
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
bergeron
reviewed
Nov 4, 2024
sahar-fehri
added
the
needs-assets-ux-review
A shared label between the Assets and UX team to flag PRs ready for consolidated team review.
label
Nov 4, 2024
sahar-fehri
force-pushed
the
feat/multi-chain-for-account-tracker-controller-v2
branch
from
November 4, 2024 19:18
a59f0d7
to
3068288
Compare
bergeron
reviewed
Nov 5, 2024
bergeron
reviewed
Nov 5, 2024
7 tasks
github-merge-queue bot
pushed a commit
that referenced
this pull request
Nov 13, 2024
<!-- Please submit this PR as a draft initially. Do not mark it as "Ready for review" until the template has been completely filled out, and PR status checks have passed at least once. --> ## **Description** There is a race condition in our testing setup, which causes that the expected fixtures state, not being there when we start the test. This has been surfaced in [this branch](#28277), where the account tracker multi polling is being added. The problem is that if we don't have the AccountTracker in state when the `resetState` function is called (at the beginning of wallet loading) the balance will remain loading until we refresh the wallet. Edit: performing the load state early in the test setup fixes the issue. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28421?quickstart=1) ## **Related issues** Fixes: MetaMask/MetaMask-planning#3627 ## **Manual testing steps** 1. Check all tests continue to pass 2. Check this changes fix this branch ENS test https://github.com/MetaMask/metamask-extension/pull/28402/files#diff-1acb7898d60977530c97169551d22dbe477a4e3aeb74f1f14bf2eea0b4d75d35 . Alternatively, see videos below with before and after behaviours ## **Screenshots/Recordings** <!-- If applicable, add screenshots and/or recordings to visualize the before and after of your change. --> ### **Before** https://github.com/user-attachments/assets/8f50ec04-cf96-478e-9c3c-dce54254a628 ### **After** https://github.com/user-attachments/assets/0f109b1a-9289-48d9-b337-d51890c9d448 ## **Pre-merge author checklist** - [x] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [x] I've completed the PR template to the best of my ability - [x] I’ve included tests if applicable - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.
gambinish
pushed a commit
that referenced
this pull request
Nov 13, 2024
<!-- Please submit this PR as a draft initially. Do not mark it as "Ready for review" until the template has been completely filled out, and PR status checks have passed at least once. --> ## **Description** There is a race condition in our testing setup, which causes that the expected fixtures state, not being there when we start the test. This has been surfaced in [this branch](#28277), where the account tracker multi polling is being added. The problem is that if we don't have the AccountTracker in state when the `resetState` function is called (at the beginning of wallet loading) the balance will remain loading until we refresh the wallet. Edit: performing the load state early in the test setup fixes the issue. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28421?quickstart=1) ## **Related issues** Fixes: MetaMask/MetaMask-planning#3627 ## **Manual testing steps** 1. Check all tests continue to pass 2. Check this changes fix this branch ENS test https://github.com/MetaMask/metamask-extension/pull/28402/files#diff-1acb7898d60977530c97169551d22dbe477a4e3aeb74f1f14bf2eea0b4d75d35 . Alternatively, see videos below with before and after behaviours ## **Screenshots/Recordings** <!-- If applicable, add screenshots and/or recordings to visualize the before and after of your change. --> ### **Before** https://github.com/user-attachments/assets/8f50ec04-cf96-478e-9c3c-dce54254a628 ### **After** https://github.com/user-attachments/assets/0f109b1a-9289-48d9-b337-d51890c9d448 ## **Pre-merge author checklist** - [x] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [x] I've completed the PR template to the best of my ability - [x] I’ve included tests if applicable - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.
<!-- Please submit this PR as a draft initially. Do not mark it as "Ready for review" until the template has been completely filled out, and PR status checks have passed at least once. --> ## **Description** List of failing tests: - Malicious Confirmation Signature - Bad Domain @no-mmi displays alert for domain binding and confirms - Malicious Confirmation Signature - Bad Domain @no-mmi initiates and rejects from confirmation screen - Malicious Confirmation Signature - Bad Domain @no-mmi initiates and rejects from alert friction modal - Malicious Confirmation Signature - Bad Domain @no-mmi displays alert for domain binding and confirms - Malicious Confirmation Signature - Bad Domain @no-mmi initiates and rejects from confirmation screen - Malicious Confirmation Signature - Bad Domain @no-mmi initiates and rejects from alert friction modal - smart transactions @no-mmi Completes a Swap - Simple Send Security Alert - Blockaid @no-mmi should not show security alerts for benign requests - Simple Send Security Alert - Blockaid @no-mmi should show security alerts for malicious requests - MultiRpc: should select rpc from modal - MetaMask onboarding @no-mmi doesn't make any network requests to infura before create new wallet onboarding is completed - MetaMask onboarding @no-mmi doesn't make any network requests to infura before onboarding by import is completed - MetaMask onboarding @no-mmi doesn't make any network requests to infura before create new wallet onboarding is completed - MetaMask onboarding @no-mmi doesn't make any network requests to infura before onboarding by import is completed - [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28402?quickstart=1) ## **Related issues** Fixes: ## **Manual testing steps** 1. Go to this page... 2. 3. ## **Screenshots/Recordings** Swaps https://github.com/user-attachments/assets/656ba20a-bc48-4f57-84d4-8b11e62a25cf ENS https://github.com/user-attachments/assets/aa23bb34-aeb0-48e9-af17-c98a82367437 ## **Pre-merge author checklist** - [ ] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [ ] I've completed the PR template to the best of my ability - [ ] I’ve included tests if applicable - [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [ ] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots. --------- Co-authored-by: sahar-fehri <[email protected]>
Builds ready [9aff235]
Page Load Metrics (2320 ± 145 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [c96cb5e]
Page Load Metrics (1736 ± 82 ms)
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
needs-assets-ux-review
A shared label between the Assets and UX team to flag PRs ready for consolidated team review.
team-assets
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Adds Multi chain polling for the token account tracker controller.
Related issues
Fixes:
Related: #28402
Manual testing steps
This should not result in any new visual changes/new errors
Screenshots/Recordings
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist