Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Bump
@metamask/providers
to v18 (#28757)
## **Description** The `@metamask/providers` package has been updated from v14 to v18. The breaking changes do not require any changes to the extension. They include: * Removal of certain provider features, which were later restored * Updates to JSON-RPC packages that used to impact error serialization in a breaking way, but no longer do (as of rpc-errors v7.0.1) * `webextension-polyfill` added as a peer dependency * Sub-path exports no longer work due to addition of exports and ESM build. Altogether this should result in no functional changes, aside from eliminating some redundant older copies of libraries (reducing bundle size). This update was difficult because of the need for a subpath export in `inpage.js`. We want to import just the `initializeInpageProvider` module without the rest of the package, which means we need to use a subpath export (because browserify doesn't support tree shaking). But this was challenging because the export maps added in v17 prevent the use of any subpath exports not defined in the export map. There was no entry that worked correctly across webpack and browserify. This was resolved by a new entry added in MetaMask/providers#391 (as part of v18.2.0) Changelog: https://github.com/MetaMask/providers/blob/main/CHANGELOG.md#1820 [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28757?quickstart=1) ## **Related issues** N/A ## **Manual testing steps** N/A ## **Screenshots/Recordings** N/A ## **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.
- Loading branch information