Skip to content

Commit f51d4b0

Browse files
Merge branch 'main' into chore/move-monad-testnet
2 parents 29dab08 + ede586f commit f51d4b0

File tree

138 files changed

+918
-1046
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

138 files changed

+918
-1046
lines changed

eslint-warning-thresholds.json

Lines changed: 14 additions & 249 deletions
Large diffs are not rendered by default.

eslint.config.mjs

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,11 @@ const config = createConfig([
8282
rules: {
8383
// TODO: These rules created more errors after the upgrade to ESLint 9.
8484
// Re-enable these rules and address any lint violations.
85-
'jest/no-conditional-in-test': 'warn',
8685
'jest/prefer-lowercase-title': 'warn',
8786
'jest/prefer-strict-equal': 'warn',
87+
88+
// TODO: Re-enable this rule
89+
'jest/unbound-method': 'off',
8890
},
8991
settings: {
9092
node: {
@@ -160,7 +162,6 @@ const config = createConfig([
160162
'@typescript-eslint/no-base-to-string': 'warn',
161163
'@typescript-eslint/no-duplicate-enum-values': 'warn',
162164
'@typescript-eslint/no-misused-promises': 'warn',
163-
'@typescript-eslint/no-unsafe-enum-comparison': 'warn',
164165
'@typescript-eslint/no-unused-vars': 'warn',
165166
'@typescript-eslint/only-throw-error': 'warn',
166167
'@typescript-eslint/prefer-promise-reject-errors': 'warn',
@@ -250,6 +251,17 @@ const config = createConfig([
250251
'n/no-deprecated-api': 'off',
251252
},
252253
},
254+
{
255+
files: [
256+
'packages/notification-services-controller/src/NotificationServicesPushController/services/push/*-web.ts',
257+
'packages/notification-services-controller/src/NotificationServicesPushController/web/**/*.ts',
258+
],
259+
rules: {
260+
// These files use `self` because they're written for a service worker context.
261+
// TODO: Move these files to the extension repository, `core` is just for platform-agnostic code.
262+
'consistent-this': 'off',
263+
},
264+
},
253265
]);
254266

255267
export default config;

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@metamask/core-monorepo",
3-
"version": "666.0.0",
3+
"version": "667.0.0",
44
"private": true,
55
"description": "Monorepo for packages shared between MetaMask clients",
66
"repository": {
@@ -56,10 +56,10 @@
5656
"@lavamoat/allow-scripts": "^3.0.4",
5757
"@lavamoat/preinstall-always-fail": "^2.1.0",
5858
"@metamask/create-release-branch": "^4.1.3",
59-
"@metamask/eslint-config": "^14.0.0",
60-
"@metamask/eslint-config-jest": "^14.0.0",
59+
"@metamask/eslint-config": "^14.1.0",
60+
"@metamask/eslint-config-jest": "^14.1.0",
6161
"@metamask/eslint-config-nodejs": "^14.0.0",
62-
"@metamask/eslint-config-typescript": "^14.0.0",
62+
"@metamask/eslint-config-typescript": "^14.1.0",
6363
"@metamask/eth-block-tracker": "^14.0.0",
6464
"@metamask/eth-json-rpc-provider": "^5.0.1",
6565
"@metamask/json-rpc-engine": "^10.1.1",
@@ -76,7 +76,7 @@
7676
"babel-jest": "^29.7.0",
7777
"chalk": "^4.1.2",
7878
"depcheck": "^1.4.7",
79-
"eslint": "^9.11.0",
79+
"eslint": "^9.39.1",
8080
"eslint-config-prettier": "^9.1.0",
8181
"eslint-import-resolver-typescript": "^3.6.3",
8282
"eslint-plugin-import-x": "^4.3.0",

packages/account-tree-controller/CHANGELOG.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [3.0.0]
11+
12+
### Changed
13+
14+
- **BREAKING:** Bump `@metamask/multichain-account-service` from `^2.0.0` to `^3.0.0` ([#7100](https://github.com/MetaMask/core/pull/7100))
15+
1016
## [2.0.0]
1117

1218
### Changed
@@ -393,7 +399,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
393399
- Initial release ([#5847](https://github.com/MetaMask/core/pull/5847))
394400
- Grouping accounts into 3 main categories: Entropy source, Snap ID, keyring types.
395401

396-
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/[email protected]
402+
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/[email protected]
403+
[3.0.0]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]
397404
[2.0.0]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]
398405
[1.6.0]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]
399406
[1.5.0]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]

packages/account-tree-controller/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@metamask/account-tree-controller",
3-
"version": "2.0.0",
3+
"version": "3.0.0",
44
"description": "Controller to group account together based on some pre-defined rules",
55
"keywords": [
66
"MetaMask",
@@ -63,7 +63,7 @@
6363
"@metamask/auto-changelog": "^3.4.4",
6464
"@metamask/keyring-api": "^21.0.0",
6565
"@metamask/keyring-controller": "^24.0.0",
66-
"@metamask/multichain-account-service": "^2.1.0",
66+
"@metamask/multichain-account-service": "^3.0.0",
6767
"@metamask/profile-sync-controller": "^26.0.0",
6868
"@metamask/providers": "^22.1.0",
6969
"@metamask/snaps-controllers": "^14.0.1",
@@ -81,7 +81,7 @@
8181
"@metamask/account-api": "^0.12.0",
8282
"@metamask/accounts-controller": "^34.0.0",
8383
"@metamask/keyring-controller": "^24.0.0",
84-
"@metamask/multichain-account-service": "^2.0.0",
84+
"@metamask/multichain-account-service": "^3.0.0",
8585
"@metamask/profile-sync-controller": "^26.0.0",
8686
"@metamask/providers": "^22.0.0",
8787
"@metamask/snaps-controllers": "^14.0.0",

packages/approval-controller/src/ApprovalController.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ import {
1111
import { errorCodes, JsonRpcError } from '@metamask/rpc-errors';
1212
import { nanoid } from 'nanoid';
1313

14-
import { flushPromises } from '../../../tests/helpers';
1514
import type {
1615
AddApprovalOptions,
1716
ApprovalControllerActions,
@@ -33,6 +32,7 @@ import {
3332
MissingApprovalFlowError,
3433
NoApprovalFlowsError,
3534
} from './errors';
35+
import { flushPromises } from '../../../tests/helpers';
3636

3737
jest.mock('nanoid');
3838

packages/approval-controller/src/ApprovalController.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -369,13 +369,13 @@ export class ApprovalController extends BaseController<
369369
ApprovalControllerState,
370370
ApprovalControllerMessenger
371371
> {
372-
#approvals: Map<string, ApprovalCallbacks>;
372+
readonly #approvals: Map<string, ApprovalCallbacks>;
373373

374-
#origins: Map<string, Map<string, number>>;
374+
readonly #origins: Map<string, Map<string, number>>;
375375

376-
#showApprovalRequest: () => void;
376+
readonly #showApprovalRequest: () => void;
377377

378-
#typesExcludedFromRateLimiting: string[];
378+
readonly #typesExcludedFromRateLimiting: string[];
379379

380380
/**
381381
* Construct an Approval controller.
@@ -615,8 +615,6 @@ export class ApprovalController extends BaseController<
615615
if (origin) {
616616
return Array.from(
617617
(this.#origins.get(origin) || new Map()).values(),
618-
// TODO: Either fix this lint violation or explain why it's necessary to ignore.
619-
// eslint-disable-next-line @typescript-eslint/restrict-plus-operands
620618
).reduce((total, value) => total + value, 0);
621619
}
622620

packages/assets-controllers/CHANGELOG.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [88.0.0]
11+
12+
### Changed
13+
14+
- **BREAKING:** Bump `@metamask/account-tree-controller` from `^2.0.0` to `^3.0.0` ([#7100](https://github.com/MetaMask/core/pull/7100))
15+
- **BREAKING:** Bump `@metamask/multichain-account-service` from `^2.0.0` to `^3.0.0` ([#7100](https://github.com/MetaMask/core/pull/7100))
16+
1017
## [87.1.1]
1118

1219
### Changed
@@ -2256,7 +2263,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
22562263
22572264
- Use Ethers for AssetsContractController ([#845](https://github.com/MetaMask/core/pull/845))
22582265
2259-
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/[email protected]
2266+
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/[email protected]
2267+
[88.0.0]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]
22602268
[87.1.1]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]
22612269
[87.1.0]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]
22622270
[87.0.0]: https://github.com/MetaMask/core/compare/@metamask/[email protected]...@metamask/[email protected]

packages/assets-controllers/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@metamask/assets-controllers",
3-
"version": "87.1.1",
3+
"version": "88.0.0",
44
"description": "Controllers which manage interactions involving ERC-20, ERC-721, and ERC-1155 tokens (including NFTs)",
55
"keywords": [
66
"MetaMask",
@@ -82,7 +82,7 @@
8282
"devDependencies": {
8383
"@babel/runtime": "^7.23.9",
8484
"@metamask/account-api": "^0.12.0",
85-
"@metamask/account-tree-controller": "^2.0.0",
85+
"@metamask/account-tree-controller": "^3.0.0",
8686
"@metamask/accounts-controller": "^34.0.0",
8787
"@metamask/approval-controller": "^8.0.0",
8888
"@metamask/auto-changelog": "^3.4.4",
@@ -91,7 +91,7 @@
9191
"@metamask/keyring-controller": "^24.0.0",
9292
"@metamask/keyring-internal-api": "^9.0.0",
9393
"@metamask/keyring-snap-client": "^8.0.0",
94-
"@metamask/multichain-account-service": "^2.1.0",
94+
"@metamask/multichain-account-service": "^3.0.0",
9595
"@metamask/network-controller": "^25.0.0",
9696
"@metamask/permission-controller": "^12.1.0",
9797
"@metamask/phishing-controller": "^15.0.0",
@@ -115,7 +115,7 @@
115115
"webextension-polyfill": "^0.12.0"
116116
},
117117
"peerDependencies": {
118-
"@metamask/account-tree-controller": "^2.0.0",
118+
"@metamask/account-tree-controller": "^3.0.0",
119119
"@metamask/accounts-controller": "^34.0.0",
120120
"@metamask/approval-controller": "^8.0.0",
121121
"@metamask/core-backend": "^4.0.0",

packages/assets-controllers/src/NftController.test.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -583,8 +583,6 @@ describe('NftController', () => {
583583
'mainnet',
584584
);
585585
await expect(erc721Result).rejects.toThrow(
586-
// TODO: Either fix this lint violation or explain why it's necessary to ignore.
587-
// eslint-disable-next-line @typescript-eslint/restrict-template-expressions
588586
`Suggested NFT of type ${ERC721} does not match received type ${ERC1155}`,
589587
);
590588
});
@@ -2485,12 +2483,8 @@ describe('NftController', () => {
24852483
.reply(200, {
24862484
name: 'name (directly from tokenURI)',
24872485
description: 'description (directly from tokenURI)',
2488-
// TODO: Either fix this lint violation or explain why it's necessary to ignore.
2489-
// eslint-disable-next-line @typescript-eslint/naming-convention
24902486
external_link: null,
24912487
image: 'image (directly from tokenURI)',
2492-
// TODO: Either fix this lint violation or explain why it's necessary to ignore.
2493-
// eslint-disable-next-line @typescript-eslint/naming-convention
24942488
animation_url: null,
24952489
});
24962490

0 commit comments

Comments
 (0)