diff --git a/.github/workflows/lint-build-test.yml b/.github/workflows/lint-build-test.yml index cc4849112f..837a02f2ba 100644 --- a/.github/workflows/lint-build-test.yml +++ b/.github/workflows/lint-build-test.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node-version: [16.x, 18.x, 20.x] + node-version: [18.x, 20.x] outputs: child-workspace-package-names: ${{ steps.workspace-package-names.outputs.child-workspace-package-names }} steps: @@ -105,7 +105,7 @@ jobs: needs: prepare strategy: matrix: - node-version: [16.x, 18.x, 20.x] + node-version: [18.x, 20.x] package-name: ${{ fromJson(needs.prepare.outputs.child-workspace-package-names) }} steps: - uses: actions/checkout@v3 diff --git a/.nvmrc b/.nvmrc index 6f7f377bf5..b009dfb9d9 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -v16 +lts/* diff --git a/constraints.pro b/constraints.pro index 985205b5a5..84cc63f1b5 100644 --- a/constraints.pro +++ b/constraints.pro @@ -408,8 +408,8 @@ gen_enforced_dependency(WorkspaceCwd, DependencyIdent, CorrectPeerDependencyRang atom_concat('^', CurrentDependencyVersion, CorrectPeerDependencyRange) ). -% All packages must specify a minimum Node version of 16. -gen_enforced_field(WorkspaceCwd, 'engines.node', '>=16.0.0'). +% All packages must specify a minimum Node version of 18. +gen_enforced_field(WorkspaceCwd, 'engines.node', '^18.18 || >=20'). % All published packages are public. gen_enforced_field(WorkspaceCwd, 'publishConfig.access', 'public') :- diff --git a/docs/contributing.md b/docs/contributing.md index 79f13d3990..55f2c9b9f3 100644 --- a/docs/contributing.md +++ b/docs/contributing.md @@ -2,8 +2,8 @@ ## Getting started -- Install [Node.js](https://nodejs.org) version 16. - - If you're using [NVM](https://github.com/creationix/nvm#installation) (recommended), `nvm use` will ensure that the right version is installed. +- Install the current LTS version of [Node.js](https://nodejs.org) + - If you are using [nvm](https://github.com/creationix/nvm#installation) (recommended) running `nvm install` will install the latest version and running `nvm use` will automatically choose the right node version for you. - Install [Yarn v3](https://yarnpkg.com/getting-started/install). - Run `yarn install` to install dependencies and run any required post-install scripts. - Run `yarn simple-git-hooks` to add a [Git hook](https://github.com/toplenboren/simple-git-hooks#what-is-a-git-hook) to your local development environment which will ensure that all files pass linting before you push a branch. diff --git a/package.json b/package.json index e7f873d933..a7102efe73 100644 --- a/package.json +++ b/package.json @@ -90,7 +90,7 @@ }, "packageManager": "yarn@3.3.0", "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "lavamoat": { "allowScripts": { diff --git a/packages/accounts-controller/package.json b/packages/accounts-controller/package.json index bc4ad85ca8..7f6f2cd15e 100644 --- a/packages/accounts-controller/package.json +++ b/packages/accounts-controller/package.json @@ -70,7 +70,7 @@ "@metamask/snaps-controllers": "^4.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/address-book-controller/package.json b/packages/address-book-controller/package.json index 4ef0c0880f..c53f67216b 100644 --- a/packages/address-book-controller/package.json +++ b/packages/address-book-controller/package.json @@ -56,7 +56,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/announcement-controller/package.json b/packages/announcement-controller/package.json index 084a8647ed..bfa44cdbc0 100644 --- a/packages/announcement-controller/package.json +++ b/packages/announcement-controller/package.json @@ -54,7 +54,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/approval-controller/package.json b/packages/approval-controller/package.json index 90ed56f94a..bfaef0c883 100644 --- a/packages/approval-controller/package.json +++ b/packages/approval-controller/package.json @@ -58,7 +58,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/assets-controllers/package.json b/packages/assets-controllers/package.json index 68ffa81d55..2b92f9e363 100644 --- a/packages/assets-controllers/package.json +++ b/packages/assets-controllers/package.json @@ -95,7 +95,7 @@ "@metamask/preferences-controller": "^9.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/base-controller/package.json b/packages/base-controller/package.json index 90d4fe3f82..5a515d8afe 100644 --- a/packages/base-controller/package.json +++ b/packages/base-controller/package.json @@ -56,7 +56,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/build-utils/package.json b/packages/build-utils/package.json index 60b52b6a5b..f8f8d90079 100644 --- a/packages/build-utils/package.json +++ b/packages/build-utils/package.json @@ -56,7 +56,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/composable-controller/package.json b/packages/composable-controller/package.json index 772a743b39..da4d357029 100644 --- a/packages/composable-controller/package.json +++ b/packages/composable-controller/package.json @@ -57,7 +57,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/controller-utils/package.json b/packages/controller-utils/package.json index e4eee16c6a..531b82fb81 100644 --- a/packages/controller-utils/package.json +++ b/packages/controller-utils/package.json @@ -63,7 +63,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/ens-controller/package.json b/packages/ens-controller/package.json index bab30fe118..cc5ff3ea57 100644 --- a/packages/ens-controller/package.json +++ b/packages/ens-controller/package.json @@ -62,7 +62,7 @@ "@metamask/network-controller": "^18.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/eth-json-rpc-provider/package.json b/packages/eth-json-rpc-provider/package.json index aff9660f15..94f7b8fff8 100644 --- a/packages/eth-json-rpc-provider/package.json +++ b/packages/eth-json-rpc-provider/package.json @@ -62,7 +62,7 @@ }, "packageManager": "yarn@3.3.0", "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/gas-fee-controller/package.json b/packages/gas-fee-controller/package.json index a4b21b23c4..60e79fab20 100644 --- a/packages/gas-fee-controller/package.json +++ b/packages/gas-fee-controller/package.json @@ -71,7 +71,7 @@ "@metamask/network-controller": "^18.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/json-rpc-engine/package.json b/packages/json-rpc-engine/package.json index bc10052229..e4b4ead38d 100644 --- a/packages/json-rpc-engine/package.json +++ b/packages/json-rpc-engine/package.json @@ -67,7 +67,7 @@ }, "packageManager": "yarn@3.3.0", "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/json-rpc-middleware-stream/package.json b/packages/json-rpc-middleware-stream/package.json index 87e636653c..b0690a9f92 100644 --- a/packages/json-rpc-middleware-stream/package.json +++ b/packages/json-rpc-middleware-stream/package.json @@ -61,7 +61,7 @@ "webextension-polyfill-ts": "^0.26.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/keyring-controller/package.json b/packages/keyring-controller/package.json index e053db9e30..0850e866e2 100644 --- a/packages/keyring-controller/package.json +++ b/packages/keyring-controller/package.json @@ -74,7 +74,7 @@ "uuid": "^8.3.2" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/logging-controller/package.json b/packages/logging-controller/package.json index 023479f8f6..c3347fb608 100644 --- a/packages/logging-controller/package.json +++ b/packages/logging-controller/package.json @@ -56,7 +56,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/message-manager/package.json b/packages/message-manager/package.json index 17bf0fd134..36f5047733 100644 --- a/packages/message-manager/package.json +++ b/packages/message-manager/package.json @@ -60,7 +60,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/name-controller/package.json b/packages/name-controller/package.json index a8ecafea8d..776d1c7368 100644 --- a/packages/name-controller/package.json +++ b/packages/name-controller/package.json @@ -57,7 +57,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/network-controller/package.json b/packages/network-controller/package.json index a26efd025b..e561a540e4 100644 --- a/packages/network-controller/package.json +++ b/packages/network-controller/package.json @@ -74,7 +74,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/notification-controller/package.json b/packages/notification-controller/package.json index 6f61db3235..1c314687fb 100644 --- a/packages/notification-controller/package.json +++ b/packages/notification-controller/package.json @@ -56,7 +56,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/permission-controller/package.json b/packages/permission-controller/package.json index 0356c20241..65e4d498d2 100644 --- a/packages/permission-controller/package.json +++ b/packages/permission-controller/package.json @@ -66,7 +66,7 @@ "@metamask/approval-controller": "^6.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/permission-log-controller/package.json b/packages/permission-log-controller/package.json index b2d18735c1..e0b2319b58 100644 --- a/packages/permission-log-controller/package.json +++ b/packages/permission-log-controller/package.json @@ -59,7 +59,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/phishing-controller/package.json b/packages/phishing-controller/package.json index a1a9f923b5..8c1cfe43c2 100644 --- a/packages/phishing-controller/package.json +++ b/packages/phishing-controller/package.json @@ -60,7 +60,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/polling-controller/package.json b/packages/polling-controller/package.json index 27c459bb0c..ca198c90c3 100644 --- a/packages/polling-controller/package.json +++ b/packages/polling-controller/package.json @@ -64,7 +64,7 @@ "@metamask/network-controller": "^18.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/preferences-controller/package.json b/packages/preferences-controller/package.json index 0a138d76bc..77ff607ba2 100644 --- a/packages/preferences-controller/package.json +++ b/packages/preferences-controller/package.json @@ -60,7 +60,7 @@ "@metamask/keyring-controller": "^14.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/queued-request-controller/package.json b/packages/queued-request-controller/package.json index 0fb608c171..4e0be542f0 100644 --- a/packages/queued-request-controller/package.json +++ b/packages/queued-request-controller/package.json @@ -69,7 +69,7 @@ "@metamask/selected-network-controller": "^10.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/rate-limit-controller/package.json b/packages/rate-limit-controller/package.json index b2da9d5b33..8edd01c7a7 100644 --- a/packages/rate-limit-controller/package.json +++ b/packages/rate-limit-controller/package.json @@ -56,7 +56,7 @@ "typescript": "~4.8.4" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/selected-network-controller/package.json b/packages/selected-network-controller/package.json index 37773958e0..23a38a76ec 100644 --- a/packages/selected-network-controller/package.json +++ b/packages/selected-network-controller/package.json @@ -67,7 +67,7 @@ "@metamask/permission-controller": "^9.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/signature-controller/package.json b/packages/signature-controller/package.json index 25f3abf96e..54115b4cdf 100644 --- a/packages/signature-controller/package.json +++ b/packages/signature-controller/package.json @@ -67,7 +67,7 @@ "@metamask/logging-controller": "^3.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/transaction-controller/package.json b/packages/transaction-controller/package.json index adddd09d03..aa078554cb 100644 --- a/packages/transaction-controller/package.json +++ b/packages/transaction-controller/package.json @@ -87,7 +87,7 @@ "@metamask/network-controller": "^18.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public", diff --git a/packages/user-operation-controller/package.json b/packages/user-operation-controller/package.json index df66a68824..8e6c38ea85 100644 --- a/packages/user-operation-controller/package.json +++ b/packages/user-operation-controller/package.json @@ -77,7 +77,7 @@ "@metamask/transaction-controller": "^25.0.0" }, "engines": { - "node": ">=16.0.0" + "node": "^18.18 || >=20" }, "publishConfig": { "access": "public",