Skip to content
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

feat: Integrate new TokenListController polling pattern [Extension] #28198

Closed
wants to merge 65 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
85fe12d
bump asset controllers to 39
bergeron Oct 22, 2024
0f3cd64
update ConfirmTransaction
bergeron Oct 22, 2024
bdf921b
fix useGasFeeEstimates unit test
bergeron Oct 22, 2024
9bc4ecf
fix usePolling tests
bergeron Oct 23, 2024
9b1529b
bump controller utils
bergeron Oct 23, 2024
c8bcc0b
remove patch
bergeron Oct 23, 2024
d1a3782
Merge branch 'develop' into brian/asset-controller-39
bergeron Oct 23, 2024
05fd6ef
Update LavaMoat policies
metamaskbot Oct 23, 2024
9dfdfa8
lint
bergeron Oct 23, 2024
04ea3d6
Merge branch 'brian/asset-controller-39' of github.com:MetaMask/metam…
bergeron Oct 23, 2024
cf66072
Merge branch 'develop' into brian/asset-controller-39
bergeron Oct 24, 2024
785de28
initial multi chain polling for currency and token rates
bergeron Oct 29, 2024
f461767
fix testnets
bergeron Oct 29, 2024
f1da818
only refetch prices on chains whose tokens changed
bergeron Oct 29, 2024
878f407
poll multiple native currencies
bergeron Oct 30, 2024
074c5fc
feat: add tokenListStartPolling and tokenListStopPollingByPollingToke…
gambinish Oct 30, 2024
e8a9d6a
fix test
bergeron Oct 30, 2024
245f8d3
yarn dedupe
bergeron Oct 30, 2024
1afebee
Update LavaMoat policies
metamaskbot Oct 30, 2024
e99e2ef
Merge branch 'develop' into brian/currency-rate-multichain-polling2
bergeron Oct 30, 2024
ca590ec
fix e2e test mocks
bergeron Oct 30, 2024
d2191ac
Merge branch 'develop' of github.com:MetaMask/metamask-extension into…
bergeron Oct 30, 2024
6321d83
feat: Bind new polling methods in metamask state
gambinish Oct 30, 2024
0633b8e
feat: Introduce useTokenListPolling hook
gambinish Oct 30, 2024
5a57889
chore: Remove chainId from constructor of TokenListController
gambinish Oct 30, 2024
70c0db4
fix e2e test
bergeron Oct 30, 2024
6b7df4d
.
bergeron Oct 30, 2024
4e816c2
lint
bergeron Oct 30, 2024
aaef377
fix e2e test
bergeron Oct 30, 2024
48bff46
Merge branch 'brian/currency-rate-multichain-polling2' of github.com:…
bergeron Oct 31, 2024
0450b04
package.json
bergeron Oct 31, 2024
2e26728
fix: Update comment
gambinish Oct 31, 2024
9d21f84
chore: Cleanup
gambinish Oct 31, 2024
b28d396
chore: Cleanup
gambinish Oct 31, 2024
fdc04ad
Merge branch 'develop' of github.com:MetaMask/metamask-extension into…
bergeron Oct 31, 2024
3ec3574
bump controller preview version
bergeron Oct 31, 2024
7c78314
fix: Provide chainId in contructor of TokenList
gambinish Oct 31, 2024
2a51a23
chore: Consider global settings when useTokeListPolling
gambinish Oct 31, 2024
0557e3f
fix: actions should only accept a single hook, multiPolling will dest…
gambinish Oct 31, 2024
a216bc9
chore: Remove comments
gambinish Oct 31, 2024
8810e88
chore: Incorporate tokensChainCache selector in useTokenListPolling hook
gambinish Oct 31, 2024
dcc8a64
Merge branch 'develop' into brian/multiexchangerate
bergeron Oct 31, 2024
3f772a2
chore: Add tokenList global context
gambinish Oct 31, 2024
92c22ea
fix: Correct naming convention in context
gambinish Oct 31, 2024
fc9a8ea
chore: Include tokenList in hook result
gambinish Oct 31, 2024
0e7a872
fix: fix lint
sahar-fehri Oct 31, 2024
ea95aca
fix: update js file to tsx
sahar-fehri Oct 31, 2024
3bf7b78
Merge branch 'develop' into brian/multiexchangerate
sahar-fehri Nov 1, 2024
bb1f278
make polling input a chain id
bergeron Nov 1, 2024
14dc84b
Merge branch 'develop' into brian/multiexchangerate
bergeron Nov 1, 2024
0af4924
fix: Correctly bind controller method to action
gambinish Nov 1, 2024
090390f
fix: Correct usage of tokenListStartPolling action
gambinish Nov 1, 2024
0efe6ed
Merge branch 'brian/multiexchangerate' into 3429_tokenlist-controller…
gambinish Nov 1, 2024
a02d772
fix: Remove action should remove polling token from AppState
gambinish Nov 1, 2024
3e4a2a3
Merge branch '3429_tokenlist-controller-polling' of github.com:MetaMa…
gambinish Nov 1, 2024
2e54266
chore: Merge main, address conflicts
gambinish Nov 4, 2024
90bd51c
fix: Missed unresolved merge conflict
gambinish Nov 4, 2024
b7e9327
fix: Leverage preview build of core
gambinish Nov 4, 2024
731baa2
fix: Update fixture builder to include tokenChainsCache
gambinish Nov 4, 2024
d9a3f33
Merge branch 'develop' into 3429_tokenlist-controller-polling
gambinish Nov 4, 2024
c404ccb
Update LavaMoat policies
metamaskbot Nov 4, 2024
7a0cac3
fix: Remove deprecated start and stop tokenListPolling
gambinish Nov 4, 2024
558b5c8
Merge branch '3429_tokenlist-controller-polling' of github.com:MetaMa…
gambinish Nov 4, 2024
5fc34e4
fix: Lint and cleanup comments
gambinish Nov 4, 2024
9b9bbc5
chore: Lint useTokenListPolling hook
gambinish Nov 4, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
only refetch prices on chains whose tokens changed
  • Loading branch information
bergeron committed Oct 29, 2024
commit f1da818422fceb7eceb9ca274bae56fe0a6f6586
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -131,7 +131,7 @@
"attributions:generate": "./development/generate-attributions.sh"
},
"resolutions": {
"@metamask/assets-controllers": "patch:@metamask-previews/assets-controllers@40.0.0-preview-c6d939c9#~/.yarn/patches/@metamask-assets-controllers-npm-39.0.0-57b3d695bb.patch",
"@metamask/assets-controllers": "patch:@metamask-previews/assets-controllers@40.0.0-preview-fa7d96bb#~/.yarn/patches/@metamask-assets-controllers-npm-39.0.0-57b3d695bb.patch",
"chokidar": "^3.6.0",
"gridplus-sdk/elliptic": "^6.5.7",
"gridplus-sdk/secp256k1": "^5.0.1",
16 changes: 8 additions & 8 deletions yarn.lock
Original file line number Diff line number Diff line change
@@ -4704,9 +4704,9 @@ __metadata:
languageName: node
linkType: hard

"@metamask-previews/assets-controllers@npm:40.0.0-preview-c6d939c9":
version: 40.0.0-preview-c6d939c9
resolution: "@metamask-previews/assets-controllers@npm:40.0.0-preview-c6d939c9"
"@metamask-previews/assets-controllers@npm:40.0.0-preview-fa7d96bb":
version: 40.0.0-preview-fa7d96bb
resolution: "@metamask-previews/assets-controllers@npm:40.0.0-preview-fa7d96bb"
dependencies:
"@ethereumjs/util": "npm:^8.1.0"
"@ethersproject/address": "npm:^5.7.0"
@@ -4738,7 +4738,7 @@ __metadata:
"@metamask/keyring-controller": ^17.0.0
"@metamask/network-controller": ^22.0.0
"@metamask/preferences-controller": ^13.0.0
checksum: 10/7a6057c98033238f7f158abc34518f051e30267b8884538b2a83e6c57b56ed5f27acb2b7666904a8b0e9fdb6bc5b92521f7abf2f99d234fc171f00a1ac3d1305
checksum: 10/b4ad08d082770e7947b2c0fce3926ab8776394b15079d8b5c3696bb7bb2db9698192580d895dcb45a6d5497f105576acc4e504987a17c19f541e5ba74b93bb7a
languageName: node
linkType: hard

@@ -4851,9 +4851,9 @@ __metadata:
languageName: node
linkType: hard

"@metamask/assets-controllers@patch:@metamask-previews/assets-controllers@40.0.0-preview-c6d939c9#~/.yarn/patches/@metamask-assets-controllers-npm-39.0.0-57b3d695bb.patch":
version: 40.0.0-preview-c6d939c9
resolution: "@metamask/assets-controllers@patch:@metamask-previews/assets-controllers@npm%3A40.0.0-preview-c6d939c9#~/.yarn/patches/@metamask-assets-controllers-npm-39.0.0-57b3d695bb.patch::version=40.0.0-preview-c6d939c9&hash=e14ff8"
"@metamask/assets-controllers@patch:@metamask-previews/assets-controllers@40.0.0-preview-fa7d96bb#~/.yarn/patches/@metamask-assets-controllers-npm-39.0.0-57b3d695bb.patch":
version: 40.0.0-preview-fa7d96bb
resolution: "@metamask/assets-controllers@patch:@metamask-previews/assets-controllers@npm%3A40.0.0-preview-fa7d96bb#~/.yarn/patches/@metamask-assets-controllers-npm-39.0.0-57b3d695bb.patch::version=40.0.0-preview-fa7d96bb&hash=e14ff8"
dependencies:
"@ethereumjs/util": "npm:^8.1.0"
"@ethersproject/address": "npm:^5.7.0"
@@ -4885,7 +4885,7 @@ __metadata:
"@metamask/keyring-controller": ^17.0.0
"@metamask/network-controller": ^22.0.0
"@metamask/preferences-controller": ^13.0.0
checksum: 10/45d670a1484eea4005c6f7d341ff0c27115c23a39b753b90a0babcf18b3baa9767180590912c4943678f19c63b7821908883fc0ddcdf3c92e9abb3cde4bd31e2
checksum: 10/f24fe4a422fe68d3df6473611680459cff1651e1eb6d006b90f2e91a6df5a5588aa101eb5f9b2d30e298c499e8e7c71ef69bb95720df13818f5a032702e73d9f
languageName: node
linkType: hard