From a3acb59af82edafa191b97766444160de919e82f Mon Sep 17 00:00:00 2001 From: Monte Lai Date: Thu, 4 Jul 2024 05:45:34 +0800 Subject: [PATCH] Release/170.0.0 (#4498) ## Explanation Create release for: - `@metamask/accounts-controller` to ^17.2.0 - `@metamask/gas-fee-controller` to ^18.0.0 - `@metamask/transaction-controller` to ^34.0.0 - `@metamask/user-operation-controller` to ^13.0.0 ## References ## Changelog ### `@metamask/accounts-controller` - **ADDED**: `accountAdded` and `accountRemoved` events ([#4496](https://github.com/MetaMask/core/pull/4496)) - **ADDED**: Export `AccountsControllerListMultichainAccounts`,`AccountsControllerGetSelectedMultichainAccount`,`AccountsControllerGetNextAvailableAccountName}Action` actions ([#4497](https://github.com/MetaMask/core/pull/4497)) - **FIXED**: Use `listMultichainAccounts` for non-EVM specific methods. ([#4494](https://github.com/MetaMask/core/pull/4494)) - **FIXED**: Set `lastSelected` for initial account ([#4494](https://github.com/MetaMask/core/pull/4494)) ### `@metamask/gas-fee-controller` - **BREAKING**: Added back the constructor options legacyAPIEndpoint and EIP1559APIEndpoint. These URLs are no longer hardcoded within the controller. - **BREAKING**: Removed the infuraAPIKey. This was used to construct and send the Authorization header for Infura gas API requests. ([#4446](https://github.com/MetaMask/core/pull/4446)) - **CHANGED**: Changing `providerConfig` to `selectedNetworkClientId` ([#4356](https://github.com/MetaMask/core/pull/4356)) - ### `@metamask/user-operation-controller` - **BREAKING:** Bump dependency and peer dependency `@metamask/gas-fee-controller` to `^18.0.0` ([#4498](https://github.com/MetaMask/core/pull/4498)) - **BREAKING:** Bump dependency and peer dependency `@metamask/transaction-controller` to `^34.0.0` ([#4498](https://github.com/MetaMask/core/pull/4498)) - ### `@metamask/transaction-controller` - **BREAKING:** Bump dependency and peer dependency `@metamask/gas-fee-controller` to `^18.0.0` ([#4498](https://github.com/MetaMask/core/pull/4498)) ## 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 --------- Co-authored-by: Jongsun Suh Co-authored-by: Elliot Winkler Co-authored-by: Charly Chevalier --- package.json | 2 +- packages/accounts-controller/CHANGELOG.md | 17 +++++++++++++- packages/accounts-controller/package.json | 2 +- packages/assets-controllers/package.json | 2 +- packages/gas-fee-controller/CHANGELOG.md | 14 +++++++++++- packages/gas-fee-controller/package.json | 2 +- packages/transaction-controller/CHANGELOG.md | 10 ++++++++- packages/transaction-controller/package.json | 8 +++---- .../user-operation-controller/CHANGELOG.md | 10 ++++++++- .../user-operation-controller/package.json | 10 ++++----- yarn.lock | 22 +++++++++---------- 11 files changed, 71 insertions(+), 28 deletions(-) diff --git a/package.json b/package.json index 4b16b75512..d08f37be6b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@metamask/core-monorepo", - "version": "169.0.0", + "version": "170.0.0", "private": true, "description": "Monorepo for packages shared between MetaMask clients", "repository": { diff --git a/packages/accounts-controller/CHANGELOG.md b/packages/accounts-controller/CHANGELOG.md index 71ce27ae4d..bb3606bd4b 100644 --- a/packages/accounts-controller/CHANGELOG.md +++ b/packages/accounts-controller/CHANGELOG.md @@ -7,6 +7,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [17.2.0] + +### Added + +- Add internal actions and events to `AccountsController` ([#4496](https://github.com/MetaMask/core/pull/4496), [#4497](https://github.com/MetaMask/core/pull/4497)) + - Add events `AccountsController:accountAdded`, `AccountsController:accountRemoved`, and export corresponding event types `AccountsControllerAccountAddedEvent`, `AccountsControllerAccountRemovedEvent`. + - Export action types `AccountsControllerListMultichainAccountsAction`, `AccountsControllerGetSelectedMultichainAccountAction`, `AccountsControllerGetNextAvailableAccountNameAction`. + +### Changed + +- Improve support of non-EVM accounts ([#4494](https://github.com/MetaMask/core/pull/4494)) + - We now use `listMultichainAccounts` instead of `listAccounts` for non-EVM specific multichain methods +- Emit `selectedAccountChange` and update `lastSelected` for initial account ([#4494](https://github.com/MetaMask/core/pull/4494)) + ## [17.1.1] ### Fixed @@ -233,7 +247,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Initial release ([#1637](https://github.com/MetaMask/core/pull/1637)) -[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/accounts-controller@17.1.1...HEAD +[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/accounts-controller@17.2.0...HEAD +[17.2.0]: https://github.com/MetaMask/core/compare/@metamask/accounts-controller@17.1.1...@metamask/accounts-controller@17.2.0 [17.1.1]: https://github.com/MetaMask/core/compare/@metamask/accounts-controller@17.1.0...@metamask/accounts-controller@17.1.1 [17.1.0]: https://github.com/MetaMask/core/compare/@metamask/accounts-controller@17.0.0...@metamask/accounts-controller@17.1.0 [17.0.0]: https://github.com/MetaMask/core/compare/@metamask/accounts-controller@16.0.0...@metamask/accounts-controller@17.0.0 diff --git a/packages/accounts-controller/package.json b/packages/accounts-controller/package.json index fd19882967..0c8103e552 100644 --- a/packages/accounts-controller/package.json +++ b/packages/accounts-controller/package.json @@ -1,6 +1,6 @@ { "name": "@metamask/accounts-controller", - "version": "17.1.1", + "version": "17.2.0", "description": "Manages internal accounts", "keywords": [ "MetaMask", diff --git a/packages/assets-controllers/package.json b/packages/assets-controllers/package.json index c9fc5852c4..b6257f930e 100644 --- a/packages/assets-controllers/package.json +++ b/packages/assets-controllers/package.json @@ -47,7 +47,7 @@ "@ethersproject/contracts": "^5.7.0", "@ethersproject/providers": "^5.7.0", "@metamask/abi-utils": "^2.0.2", - "@metamask/accounts-controller": "^17.1.1", + "@metamask/accounts-controller": "^17.2.0", "@metamask/approval-controller": "^7.0.0", "@metamask/base-controller": "^6.0.0", "@metamask/contract-metadata": "^2.4.0", diff --git a/packages/gas-fee-controller/CHANGELOG.md b/packages/gas-fee-controller/CHANGELOG.md index 19e0ef69e7..0cec9acf3f 100644 --- a/packages/gas-fee-controller/CHANGELOG.md +++ b/packages/gas-fee-controller/CHANGELOG.md @@ -7,6 +7,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [18.0.0] + +### Added + +- **BREAKING:** Add constructor options to `GasFeeController`: `EIP1559APIEndpoint` (required), and `legacyAPIEndpoint` (optional) which defaults to `LEGACY_GAS_PRICES_API_URL`. ([#4446](https://github.com/MetaMask/core/pull/4446)) + - These URLs are no longer hardcoded within the controller. + +### Removed + +- **BREAKING:** Remove `infuraAPIKey` as a constructor option for `GasFeeController`. This class field was previously used to construct and send the `Authorization` header for Infura gas API requests. ([#4446](https://github.com/MetaMask/core/pull/4446)) + ## [17.0.0] ### Changed @@ -293,7 +304,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 All changes listed after this point were applied to this package following the monorepo conversion. -[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@17.0.0...HEAD +[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@18.0.0...HEAD +[18.0.0]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@17.0.0...@metamask/gas-fee-controller@18.0.0 [17.0.0]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@16.0.0...@metamask/gas-fee-controller@17.0.0 [16.0.0]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@15.1.2...@metamask/gas-fee-controller@16.0.0 [15.1.2]: https://github.com/MetaMask/core/compare/@metamask/gas-fee-controller@15.1.1...@metamask/gas-fee-controller@15.1.2 diff --git a/packages/gas-fee-controller/package.json b/packages/gas-fee-controller/package.json index d72cc271f7..9d5a588762 100644 --- a/packages/gas-fee-controller/package.json +++ b/packages/gas-fee-controller/package.json @@ -1,6 +1,6 @@ { "name": "@metamask/gas-fee-controller", - "version": "17.0.0", + "version": "18.0.0", "description": "Periodically calculates gas fee estimates based on various gas limits as well as other data displayed on transaction confirm screens", "keywords": [ "MetaMask", diff --git a/packages/transaction-controller/CHANGELOG.md b/packages/transaction-controller/CHANGELOG.md index 0eb4380faa..eca1312a1b 100644 --- a/packages/transaction-controller/CHANGELOG.md +++ b/packages/transaction-controller/CHANGELOG.md @@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [34.0.0] + +### Changed + +- **BREAKING:** Bump dependency and peer dependency `@metamask/gas-fee-controller` to `^18.0.0` ([#4498](https://github.com/MetaMask/core/pull/4498)) +- Bump dependency `@metamask/accounts-controller` to `^17.2.0` ([#4498](https://github.com/MetaMask/core/pull/4498)) + ## [33.0.1] ### Changed @@ -903,7 +910,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 All changes listed after this point were applied to this package following the monorepo conversion. -[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@33.0.1...HEAD +[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@34.0.0...HEAD +[34.0.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@33.0.1...@metamask/transaction-controller@34.0.0 [33.0.1]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@33.0.0...@metamask/transaction-controller@33.0.1 [33.0.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@32.0.0...@metamask/transaction-controller@33.0.0 [32.0.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@31.0.0...@metamask/transaction-controller@32.0.0 diff --git a/packages/transaction-controller/package.json b/packages/transaction-controller/package.json index dadf7c312e..2471fd7636 100644 --- a/packages/transaction-controller/package.json +++ b/packages/transaction-controller/package.json @@ -1,6 +1,6 @@ { "name": "@metamask/transaction-controller", - "version": "33.0.1", + "version": "34.0.0", "description": "Stores transactions alongside their periodically updated statuses and manages interactions such as approval and cancellation", "keywords": [ "MetaMask", @@ -47,12 +47,12 @@ "@ethersproject/abi": "^5.7.0", "@ethersproject/contracts": "^5.7.0", "@ethersproject/providers": "^5.7.0", - "@metamask/accounts-controller": "^17.1.1", + "@metamask/accounts-controller": "^17.2.0", "@metamask/approval-controller": "^7.0.0", "@metamask/base-controller": "^6.0.0", "@metamask/controller-utils": "^11.0.0", "@metamask/eth-query": "^4.0.0", - "@metamask/gas-fee-controller": "^17.0.0", + "@metamask/gas-fee-controller": "^18.0.0", "@metamask/metamask-eth-abis": "^3.1.1", "@metamask/network-controller": "^19.0.0", "@metamask/nonce-tracker": "^5.0.0", @@ -88,7 +88,7 @@ "@babel/runtime": "^7.23.9", "@metamask/accounts-controller": "^17.0.0", "@metamask/approval-controller": "^7.0.0", - "@metamask/gas-fee-controller": "^17.0.0", + "@metamask/gas-fee-controller": "^18.0.0", "@metamask/network-controller": "^19.0.0" }, "engines": { diff --git a/packages/user-operation-controller/CHANGELOG.md b/packages/user-operation-controller/CHANGELOG.md index 509bce212a..a47bdb0ed5 100644 --- a/packages/user-operation-controller/CHANGELOG.md +++ b/packages/user-operation-controller/CHANGELOG.md @@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [13.0.0] + +### Changed + +- **BREAKING:** Bump dependency and peer dependency `@metamask/gas-fee-controller` to `^18.0.0` ([#4498](https://github.com/MetaMask/core/pull/4498)) +- **BREAKING:** Bump dependency and peer dependency `@metamask/transaction-controller` to `^34.0.0` ([#4498](https://github.com/MetaMask/core/pull/4498)) + ## [12.0.1] ### Changed @@ -169,7 +176,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Initial Release ([#3749](https://github.com/MetaMask/core/pull/3749)) -[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/user-operation-controller@12.0.1...HEAD +[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/user-operation-controller@13.0.0...HEAD +[13.0.0]: https://github.com/MetaMask/core/compare/@metamask/user-operation-controller@12.0.1...@metamask/user-operation-controller@13.0.0 [12.0.1]: https://github.com/MetaMask/core/compare/@metamask/user-operation-controller@12.0.0...@metamask/user-operation-controller@12.0.1 [12.0.0]: https://github.com/MetaMask/core/compare/@metamask/user-operation-controller@11.0.0...@metamask/user-operation-controller@12.0.0 [11.0.0]: https://github.com/MetaMask/core/compare/@metamask/user-operation-controller@10.0.0...@metamask/user-operation-controller@11.0.0 diff --git a/packages/user-operation-controller/package.json b/packages/user-operation-controller/package.json index d9b2d23f2f..864de523ef 100644 --- a/packages/user-operation-controller/package.json +++ b/packages/user-operation-controller/package.json @@ -1,6 +1,6 @@ { "name": "@metamask/user-operation-controller", - "version": "12.0.1", + "version": "13.0.0", "description": "Creates user operations and manages their life cycle", "keywords": [ "MetaMask", @@ -46,12 +46,12 @@ "@metamask/base-controller": "^6.0.0", "@metamask/controller-utils": "^11.0.0", "@metamask/eth-query": "^4.0.0", - "@metamask/gas-fee-controller": "^17.0.0", + "@metamask/gas-fee-controller": "^18.0.0", "@metamask/keyring-controller": "^17.1.0", "@metamask/network-controller": "^19.0.0", "@metamask/polling-controller": "^8.0.0", "@metamask/rpc-errors": "^6.2.1", - "@metamask/transaction-controller": "^33.0.1", + "@metamask/transaction-controller": "^34.0.0", "@metamask/utils": "^8.3.0", "bn.js": "^5.2.1", "immer": "^9.0.6", @@ -71,10 +71,10 @@ }, "peerDependencies": { "@metamask/approval-controller": "^7.0.0", - "@metamask/gas-fee-controller": "^17.0.0", + "@metamask/gas-fee-controller": "^18.0.0", "@metamask/keyring-controller": "^17.0.0", "@metamask/network-controller": "^19.0.0", - "@metamask/transaction-controller": "^33.0.0" + "@metamask/transaction-controller": "^34.0.0" }, "engines": { "node": "^18.18 || >=20" diff --git a/yarn.lock b/yarn.lock index 12c57b607c..226b1e16c3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2195,7 +2195,7 @@ __metadata: languageName: node linkType: hard -"@metamask/accounts-controller@npm:^17.1.1, @metamask/accounts-controller@workspace:packages/accounts-controller": +"@metamask/accounts-controller@npm:^17.2.0, @metamask/accounts-controller@workspace:packages/accounts-controller": version: 0.0.0-use.local resolution: "@metamask/accounts-controller@workspace:packages/accounts-controller" dependencies: @@ -2313,7 +2313,7 @@ __metadata: "@ethersproject/contracts": "npm:^5.7.0" "@ethersproject/providers": "npm:^5.7.0" "@metamask/abi-utils": "npm:^2.0.2" - "@metamask/accounts-controller": "npm:^17.1.1" + "@metamask/accounts-controller": "npm:^17.2.0" "@metamask/approval-controller": "npm:^7.0.0" "@metamask/auto-changelog": "npm:^3.4.4" "@metamask/base-controller": "npm:^6.0.0" @@ -2940,7 +2940,7 @@ __metadata: languageName: node linkType: hard -"@metamask/gas-fee-controller@npm:^17.0.0, @metamask/gas-fee-controller@workspace:packages/gas-fee-controller": +"@metamask/gas-fee-controller@npm:^18.0.0, @metamask/gas-fee-controller@workspace:packages/gas-fee-controller": version: 0.0.0-use.local resolution: "@metamask/gas-fee-controller@workspace:packages/gas-fee-controller" dependencies: @@ -3771,7 +3771,7 @@ __metadata: languageName: node linkType: hard -"@metamask/transaction-controller@npm:^33.0.1, @metamask/transaction-controller@workspace:packages/transaction-controller": +"@metamask/transaction-controller@npm:^34.0.0, @metamask/transaction-controller@workspace:packages/transaction-controller": version: 0.0.0-use.local resolution: "@metamask/transaction-controller@workspace:packages/transaction-controller" dependencies: @@ -3782,7 +3782,7 @@ __metadata: "@ethersproject/abi": "npm:^5.7.0" "@ethersproject/contracts": "npm:^5.7.0" "@ethersproject/providers": "npm:^5.7.0" - "@metamask/accounts-controller": "npm:^17.1.1" + "@metamask/accounts-controller": "npm:^17.2.0" "@metamask/approval-controller": "npm:^7.0.0" "@metamask/auto-changelog": "npm:^3.4.4" "@metamask/base-controller": "npm:^6.0.0" @@ -3790,7 +3790,7 @@ __metadata: "@metamask/eth-json-rpc-provider": "npm:^4.0.0" "@metamask/eth-query": "npm:^4.0.0" "@metamask/ethjs-provider-http": "npm:^0.3.0" - "@metamask/gas-fee-controller": "npm:^17.0.0" + "@metamask/gas-fee-controller": "npm:^18.0.0" "@metamask/keyring-api": "npm:^8.0.0" "@metamask/metamask-eth-abis": "npm:^3.1.1" "@metamask/network-controller": "npm:^19.0.0" @@ -3819,7 +3819,7 @@ __metadata: "@babel/runtime": ^7.23.9 "@metamask/accounts-controller": ^17.0.0 "@metamask/approval-controller": ^7.0.0 - "@metamask/gas-fee-controller": ^17.0.0 + "@metamask/gas-fee-controller": ^18.0.0 "@metamask/network-controller": ^19.0.0 languageName: unknown linkType: soft @@ -3833,12 +3833,12 @@ __metadata: "@metamask/base-controller": "npm:^6.0.0" "@metamask/controller-utils": "npm:^11.0.0" "@metamask/eth-query": "npm:^4.0.0" - "@metamask/gas-fee-controller": "npm:^17.0.0" + "@metamask/gas-fee-controller": "npm:^18.0.0" "@metamask/keyring-controller": "npm:^17.1.0" "@metamask/network-controller": "npm:^19.0.0" "@metamask/polling-controller": "npm:^8.0.0" "@metamask/rpc-errors": "npm:^6.2.1" - "@metamask/transaction-controller": "npm:^33.0.1" + "@metamask/transaction-controller": "npm:^34.0.0" "@metamask/utils": "npm:^8.3.0" "@types/jest": "npm:^27.4.1" bn.js: "npm:^5.2.1" @@ -3854,10 +3854,10 @@ __metadata: uuid: "npm:^8.3.2" peerDependencies: "@metamask/approval-controller": ^7.0.0 - "@metamask/gas-fee-controller": ^17.0.0 + "@metamask/gas-fee-controller": ^18.0.0 "@metamask/keyring-controller": ^17.0.0 "@metamask/network-controller": ^19.0.0 - "@metamask/transaction-controller": ^33.0.0 + "@metamask/transaction-controller": ^34.0.0 languageName: unknown linkType: soft