Skip to content

Commit 2b7e539

Browse files
committed
Merge branch 'main' into mikesposito/update-keyring-controller
2 parents 7bb7688 + 0430a65 commit 2b7e539

File tree

178 files changed

+3988
-1574
lines changed

Some content is hidden

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

178 files changed

+3988
-1574
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
# audit these changes on their own, and leave their analysis in a comment.
1414
# These codeowners will review this analysis, and review the policy changes in
1515
# further detail if warranted.
16-
lavamoat/ @MetaMask/extension-devs @MetaMask/policy-reviewers @MetaMask/supply-chain
16+
lavamoat/ @MetaMask/policy-reviewers
1717

1818
# The offscreen.ts script file that is included in the offscreen document html
1919
# file is responsible, at present, for loading the snaps execution environment

.github/scripts/check-template-and-add-labels.ts

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,19 @@ async function userBelongsToMetaMaskOrg(
409409
// This function checks if the PR description has a changelog entry
410410
function hasChangelogEntry(body: string): boolean {
411411
// Remove HTML comments (including multiline)
412-
const uncommentedBody = body.replace(/<!--[\s\S]*?-->/g, "");
412+
let uncommentedBody = body;
413+
let prevBody;
414+
let iterationCount = 0;
415+
const MAX_ITERATIONS = 100;
416+
do {
417+
prevBody = uncommentedBody;
418+
uncommentedBody = uncommentedBody.replace(/<!--[\s\S]*?-->/g, "");
419+
iterationCount++;
420+
if (iterationCount >= MAX_ITERATIONS) {
421+
console.warn(`Reached maximum HTML comment removal iterations (${MAX_ITERATIONS}). Input may be malformed or malicious.`);
422+
break;
423+
}
424+
} while (uncommentedBody !== prevBody);
413425

414426
// Split body into lines
415427
const lines = uncommentedBody.split(/\r?\n/);

.github/workflows/create-release-pr.yml

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -76,20 +76,21 @@ jobs:
7676
create-release-pr:
7777
needs: [resolve-bases, resolve-previous-ref]
7878
name: Create Release Pull Request using Github Tools
79-
uses: MetaMask/github-tools/.github/workflows/create-release-pr.yml@6a04e4d0c8c25680a7543cfcd2e2fb7125b6759c
80-
with:
81-
platform: extension
82-
checkout-base-branch: ${{ needs.resolve-bases.outputs.checkout_base }}
83-
release-pr-base-branch: ${{ needs.resolve-bases.outputs.release_base }}
84-
semver-version: ${{ inputs.semver-version }}
85-
previous-version-ref: ${{ needs.resolve-previous-ref.outputs.previous_ref }}
86-
github-tools-version: 6a04e4d0c8c25680a7543cfcd2e2fb7125b6759c
87-
secrets:
88-
# This token needs write permissions to metamask-extension & read permissions to metamask-planning
89-
# If called from auto-create-release-pr use the PR_TOKEN passed in as an input, if called manually use github secret token values
90-
# (this is due to github limitations on fetching secrets from called workflows).
91-
github-token: ${{ github.event_name == 'workflow_dispatch' && secrets.PR_TOKEN || secrets.github-token }}
92-
google-application-creds-base64: ${{ github.event_name == 'workflow_dispatch' && secrets.GCP_RLS_SHEET_ACCOUNT_BASE64 || secrets.google-application-creds-base64 }}
79+
runs-on: ubuntu-latest
9380
permissions:
9481
contents: write
9582
pull-requests: write
83+
steps:
84+
- name: Create Release PR
85+
uses: MetaMask/github-tools/.github/actions/[email protected]
86+
with:
87+
platform: extension
88+
checkout-base-branch: ${{ needs.resolve-bases.outputs.checkout_base }}
89+
release-pr-base-branch: ${{ needs.resolve-bases.outputs.release_base }}
90+
semver-version: ${{ inputs.semver-version }}
91+
previous-version-ref: ${{ needs.resolve-previous-ref.outputs.previous_ref }}
92+
# This token needs write permissions to metamask-extension & read permissions to metamask-planning
93+
# If called from auto-create-release-pr use the PR_TOKEN passed in as an input, if called manually use github secret token values
94+
# (this is due to github limitations on fetching secrets from called workflows).
95+
github-token: ${{ github.event_name == 'workflow_dispatch' && secrets.PR_TOKEN || secrets.github-token }}
96+
google-application-creds-base64: ${{ github.event_name == 'workflow_dispatch' && secrets.GCP_RLS_SHEET_ACCOUNT_BASE64 || secrets.google-application-creds-base64 }}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Merge Approved PR
2+
3+
on:
4+
# Trigger the workflow when a comment is created on an issue or pull request
5+
issue_comment:
6+
types: [created]
7+
8+
jobs:
9+
merge-pr:
10+
# Only run if the comment is on a PR and the comment body matches exactly "Merge my PR"
11+
if: >-
12+
github.event.issue.pull_request &&
13+
github.event.comment.body == 'Merge my PR' &&
14+
(
15+
github.event.comment.author_association == 'MEMBER' ||
16+
github.event.comment.author_association == 'OWNER'
17+
)
18+
uses: MetaMask/github-tools/.github/workflows/merge-approved-pr.yml@30baa9da0b80d94dd8bdf0b6a932c46506664857
19+
with:
20+
pr-number: ${{ github.event.issue.number }}
21+
secrets:
22+
github-token: ${{ secrets.METAMASK_EXTENSION_BRANCH_SYNC_TOKEN }}

.github/workflows/update-release-changelog.yml

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,17 @@ jobs:
4242
name: Update changelog
4343
needs: validate-branch
4444
if: needs.validate-branch.outputs.is-valid-release == 'true'
45+
runs-on: ubuntu-latest
4546
permissions:
4647
contents: write
4748
pull-requests: write
48-
uses: MetaMask/github-tools/.github/workflows/update-release-changelog.yml@36dc168896c1b496f35fc880ee8a3625b4b837ba
49-
with:
50-
release-branch: ${{ github.ref_name }}
51-
repository-url: ${{ github.server_url }}/${{ github.repository }}
52-
platform: extension
53-
github-tools-version: 36dc168896c1b496f35fc880ee8a3625b4b837ba
54-
previous-version-ref: null
55-
secrets:
56-
github-token: ${{ secrets.PR_TOKEN }}
49+
steps:
50+
- name: Update Release Changelog
51+
uses: MetaMask/github-tools/.github/actions/[email protected]
52+
with:
53+
release-branch: ${{ github.ref_name }}
54+
repository-url: ${{ github.server_url }}/${{ github.repository }}
55+
platform: extension
56+
previous-version-ref: 'null'
57+
github-tools-version: v1.1.0
58+
github-token: ${{ secrets.PR_TOKEN }}

.yarn/patches/@metamask-assets-controllers-npm-91.0.0-ea998cb0bd.patch renamed to .yarn/patches/@metamask-assets-controllers-npm-92.0.0-ea998cb0bd.patch

Lines changed: 0 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,64 +1,7 @@
1-
diff --git a/dist/TokenBalancesController.cjs b/dist/TokenBalancesController.cjs
2-
index 4918812dde60b8d0e24a7bded27d88f233968858..4e8018bce92b9e5d47fc40784409e16db22be615 100644
3-
--- a/dist/TokenBalancesController.cjs
4-
+++ b/dist/TokenBalancesController.cjs
5-
@@ -535,14 +535,16 @@ class TokenBalancesController extends (0, polling_controller_1.StaticIntervalPol
6-
}
7-
// Update with actual fetched balances only if the value has changed
8-
aggregated.forEach(({ success, value, account, token, chainId }) => {
9-
- var _a, _b, _c;
10-
+ var _a, _b;
11-
if (success && value !== undefined) {
12-
+ // Ensure all accounts we add/update are in lower-case
13-
+ const lowerCaseAccount = account.toLowerCase();
14-
const newBalance = (0, controller_utils_1.toHex)(value);
15-
const tokenAddress = checksum(token);
16-
- const currentBalance = d.tokenBalances[account]?.[chainId]?.[tokenAddress];
17-
+ const currentBalance = d.tokenBalances[lowerCaseAccount]?.[chainId]?.[tokenAddress];
18-
// Only update if the balance has actually changed
19-
if (currentBalance !== newBalance) {
20-
- ((_c = ((_a = d.tokenBalances)[_b = account] ?? (_a[_b] = {})))[chainId] ?? (_c[chainId] = {}))[tokenAddress] = newBalance;
21-
+ ((_b = ((_a = d.tokenBalances)[lowerCaseAccount] ?? (_a[lowerCaseAccount] = {})))[chainId] ?? (_b[chainId] = {}))[tokenAddress] = newBalance;
22-
}
23-
}
24-
});
25-
diff --git a/dist/TokenBalancesController.mjs b/dist/TokenBalancesController.mjs
26-
index f64d13f8de56631345a44e6ebb025e62e03f51bc..99aa7f27c574c94b26daa56091ac50d15281dd30 100644
27-
--- a/dist/TokenBalancesController.mjs
28-
+++ b/dist/TokenBalancesController.mjs
29-
@@ -531,14 +531,16 @@ export class TokenBalancesController extends StaticIntervalPollingController() {
30-
}
31-
// Update with actual fetched balances only if the value has changed
32-
aggregated.forEach(({ success, value, account, token, chainId }) => {
33-
- var _a, _b, _c;
34-
+ var _a, _b;
35-
if (success && value !== undefined) {
36-
+ // Ensure all accounts we add/update are in lower-case
37-
+ const lowerCaseAccount = account.toLowerCase();
38-
const newBalance = toHex(value);
39-
const tokenAddress = checksum(token);
40-
- const currentBalance = d.tokenBalances[account]?.[chainId]?.[tokenAddress];
41-
+ const currentBalance = d.tokenBalances[lowerCaseAccount]?.[chainId]?.[tokenAddress];
42-
// Only update if the balance has actually changed
43-
if (currentBalance !== newBalance) {
44-
- ((_c = ((_a = d.tokenBalances)[_b = account] ?? (_a[_b] = {})))[chainId] ?? (_c[chainId] = {}))[tokenAddress] = newBalance;
45-
+ ((_b = ((_a = d.tokenBalances)[lowerCaseAccount] ?? (_a[lowerCaseAccount] = {})))[chainId] ?? (_b[chainId] = {}))[tokenAddress] = newBalance;
46-
}
47-
}
48-
});
491
diff --git a/dist/token-prices-service/codefi-v2.cjs b/dist/token-prices-service/codefi-v2.cjs
502
index ba0f0c1bcbf0f231549b1ca9d3be2d1137a0d732..49af7c70a2f05d6587d960a227a724084333a942 100644
513
--- a/dist/token-prices-service/codefi-v2.cjs
524
+++ b/dist/token-prices-service/codefi-v2.cjs
53-
@@ -100,6 +100,8 @@ exports.SUPPORTED_CURRENCIES = [
54-
'mxn',
55-
// Malaysian Ringgit
56-
'myr',
57-
+ // Monad
58-
+ 'mon',
59-
// Nigerian Naira
60-
'ngn',
61-
// Norwegian Krone
625
@@ -220,43 +222,43 @@ exports.getNativeTokenAddress = getNativeTokenAddress;
636
// Source: https://github.com/consensys-vertical-apps/va-mmcx-price-api/blob/main/src/constants/slip44.ts
647
// We can only support PricesAPI V3 for EVM chains that have a CAIP-19 native asset mapping.
@@ -150,15 +93,6 @@ diff --git a/dist/token-prices-service/codefi-v2.mjs b/dist/token-prices-service
15093
index f8e7c25451281ffea43fd0425f9c2a7950ce1214..e9ef4e4a6a8f0156f8280621654c1098bf942063 100644
15194
--- a/dist/token-prices-service/codefi-v2.mjs
15295
+++ b/dist/token-prices-service/codefi-v2.mjs
153-
@@ -97,6 +97,8 @@ export const SUPPORTED_CURRENCIES = [
154-
'mxn',
155-
// Malaysian Ringgit
156-
'myr',
157-
+ // Monad
158-
+ 'mon',
159-
// Nigerian Naira
160-
'ngn',
161-
// Norwegian Krone
16296
@@ -216,43 +218,43 @@ export const getNativeTokenAddress = (chainId) => chainIdToNativeTokenAddress[ch
16397
// Source: https://github.com/consensys-vertical-apps/va-mmcx-price-api/blob/main/src/constants/slip44.ts
16498
// We can only support PricesAPI V3 for EVM chains that have a CAIP-19 native asset mapping.

CHANGELOG.md

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

88
## [Unreleased]
99

10+
## [13.11.2]
11+
12+
### Fixed
13+
14+
- fix: upgrade bitcoin snap (#38437)
15+
16+
## [13.11.1]
17+
18+
### Fixed
19+
20+
- Fixes a crash when updating Flask (#38382)
21+
1022
## [13.11.0]
1123

1224
### Added
@@ -1328,7 +1340,9 @@ authorized by the user.` error until the user fully revoked dapp
13281340
- This changelog was split off with 12.22.0
13291341
- All older changes can be found in [docs/CHANGELOG_older.md](https://github.com/MetaMask/metamask-extension/blob/main/docs/CHANGELOG_older.md)
13301342

1331-
[Unreleased]: https://github.com/MetaMask/metamask-extension/compare/v13.11.0...HEAD
1343+
[Unreleased]: https://github.com/MetaMask/metamask-extension/compare/v13.11.2...HEAD
1344+
[13.11.2]: https://github.com/MetaMask/metamask-extension/compare/v13.11.1...v13.11.2
1345+
[13.11.1]: https://github.com/MetaMask/metamask-extension/compare/v13.11.0...v13.11.1
13321346
[13.11.0]: https://github.com/MetaMask/metamask-extension/compare/v13.10.4...v13.11.0
13331347
[13.10.4]: https://github.com/MetaMask/metamask-extension/compare/v13.10.3...v13.10.4
13341348
[13.10.3]: https://github.com/MetaMask/metamask-extension/compare/v13.10.2...v13.10.3

app/_locales/en/messages.json

Lines changed: 3 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/_locales/en_GB/messages.json

Lines changed: 3 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/_locales/ga/messages.json

Lines changed: 0 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)