Skip to content

Commit

Permalink
Merge pull request #24342 from MetaMask/Version-v11.14.5
Browse files Browse the repository at this point in the history
Version v11.14.5
  • Loading branch information
danjm authored May 2, 2024
2 parents b3949d9 + 646ea2e commit ba27c66
Show file tree
Hide file tree
Showing 16 changed files with 507 additions and 129 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [11.14.5]
### Fixed
- Prevent users from making fund loss errors while editing transactions by removing the edit button when on any confirmation screen for a transaction proposed by a dapp ([#24322](https://github.com/MetaMask/metamask-extension/pull/24322))
- Reduce failed simulations on NFT mint confirmations ([#24350]https://github.com/MetaMask/metamask-extension/pull/24350)

## [11.14.4]
### Fixed
- Fix bug that could cause safe-transfer-from transactions to be converted to transfer-from transactions, by removing the edit button on the safe-transfer-from confirmation screens ([#24287](https://github.com/MetaMask/metamask-extension/pull/24287))
Expand Down Expand Up @@ -4625,7 +4630,8 @@ Update styles and spacing on the critical error page ([#20350](https://github.c
- Added the ability to restore accounts from seed words.


[Unreleased]: https://github.com/MetaMask/metamask-extension/compare/v11.14.4...HEAD
[Unreleased]: https://github.com/MetaMask/metamask-extension/compare/v11.14.5...HEAD
[11.14.5]: https://github.com/MetaMask/metamask-extension/compare/v11.14.4...v11.14.5
[11.14.4]: https://github.com/MetaMask/metamask-extension/compare/v11.14.3...v11.14.4
[11.14.3]: https://github.com/MetaMask/metamask-extension/compare/v11.14.2...v11.14.3
[11.14.2]: https://github.com/MetaMask/metamask-extension/compare/v11.14.1...v11.14.2
Expand Down
4 changes: 2 additions & 2 deletions app/scripts/lib/transaction/metrics.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,7 @@ describe('Transaction metrics', () => {
mockTransactionMeta.submittedTime = 123;

await handleTransactionConfirmed(mockTransactionMetricsRequest, {
transactionMeta: mockTransactionMeta,
...mockTransactionMeta,
actionId: mockActionId,
} as any);

Expand Down Expand Up @@ -627,7 +627,7 @@ describe('Transaction metrics', () => {
mockTransactionMetaWithBlockaid.submittedTime = 123;

await handleTransactionConfirmed(mockTransactionMetricsRequest, {
transactionMeta: mockTransactionMetaWithBlockaid,
...mockTransactionMetaWithBlockaid,
actionId: mockActionId,
} as any);

Expand Down
16 changes: 12 additions & 4 deletions app/scripts/lib/transaction/metrics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,11 @@ export type TransactionEventPayload = {
error?: string;
};

export type TransactionMetaEventPayload = TransactionMeta & {
actionId?: string;
error?: string;
};

/**
* This function is called when a transaction is added to the controller.
*
Expand Down Expand Up @@ -185,14 +190,14 @@ export const handleTransactionFailed = async (
*/
export const handleTransactionConfirmed = async (
transactionMetricsRequest: TransactionMetricsRequest,
transactionEventPayload: TransactionEventPayload,
transactionEventPayload: TransactionMetaEventPayload,
) => {
if (!transactionEventPayload.transactionMeta) {
if (Object.keys(transactionEventPayload).length === 0) {
return;
}

const extraParams = {} as Record<string, any>;
const { transactionMeta } = transactionEventPayload;
const transactionMeta = { ...transactionEventPayload };
const { txReceipt } = transactionMeta;

extraParams.gas_used = txReceipt?.gasUsed;
Expand All @@ -209,7 +214,10 @@ export const handleTransactionConfirmed = async (
await createUpdateFinalizeTransactionEventFragment({
eventName: TransactionMetaMetricsEvent.finalized,
extraParams,
transactionEventPayload,
transactionEventPayload: {
actionId: transactionMeta.actionId,
transactionMeta,
},
transactionMetricsRequest,
});
};
Expand Down
2 changes: 1 addition & 1 deletion builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ buildTypes:
env:
- INFURA_MMI_PROJECT_ID
- SEGMENT_MMI_WRITE_KEY
- SENTRY_MMI_DSN
- SENTRY_MMI_DSN: ''
- INFURA_ENV_KEY_REF: INFURA_MMI_PROJECT_ID
- SEGMENT_WRITE_KEY_REF: SEGMENT_MMI_WRITE_KEY
- ALLOW_LOCAL_SNAPS: false
Expand Down
89 changes: 79 additions & 10 deletions lavamoat/browserify/beta/policy.json
Original file line number Diff line number Diff line change
Expand Up @@ -175,23 +175,41 @@
},
"packages": {
"@ethereumjs/tx>ethereum-cryptography>@noble/curves": true,
"@ethereumjs/tx>ethereum-cryptography>@scure/bip32": true,
"@noble/hashes": true
"@ethereumjs/tx>ethereum-cryptography>@noble/hashes": true,
"@ethereumjs/tx>ethereum-cryptography>@scure/bip32": true
}
},
"@ethereumjs/tx>ethereum-cryptography>@noble/curves": {
"globals": {
"TextEncoder": true
},
"packages": {
"@noble/hashes": true
"@ethereumjs/tx>ethereum-cryptography>@noble/curves>@noble/hashes": true
}
},
"@ethereumjs/tx>ethereum-cryptography>@noble/curves>@noble/hashes": {
"globals": {
"TextEncoder": true,
"crypto": true
}
},
"@ethereumjs/tx>ethereum-cryptography>@noble/hashes": {
"globals": {
"TextEncoder": true,
"crypto": true
}
},
"@ethereumjs/tx>ethereum-cryptography>@scure/bip32": {
"packages": {
"@ethereumjs/tx>ethereum-cryptography>@noble/curves": true,
"@metamask/utils>@scure/base": true,
"@noble/hashes": true
"@ethereumjs/tx>ethereum-cryptography>@scure/bip32>@noble/hashes": true,
"@metamask/utils>@scure/base": true
}
},
"@ethereumjs/tx>ethereum-cryptography>@scure/bip32>@noble/hashes": {
"globals": {
"TextEncoder": true,
"crypto": true
}
},
"@ethersproject/abi": {
Expand Down Expand Up @@ -1394,15 +1412,25 @@
},
"packages": {
"@ethereumjs/tx>@ethereumjs/util": true,
"@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/ethjs>@metamask/ethjs-unit": true,
"@metamask/gas-fee-controller>@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/utils": true,
"bn.js": true,
"browserify>buffer": true,
"eslint>fast-deep-equal": true,
"eth-ens-namehash": true
}
},
"@metamask/gas-fee-controller>@metamask/controller-utils>@spruceid/siwe-parser": {
"globals": {
"console.error": true,
"console.log": true
},
"packages": {
"@metamask/controller-utils>@spruceid/siwe-parser>apg-js": true,
"@noble/hashes": true
}
},
"@metamask/gas-fee-controller>@metamask/polling-controller": {
"globals": {
"clearTimeout": true,
Expand Down Expand Up @@ -1660,15 +1688,25 @@
},
"packages": {
"@ethereumjs/tx>@ethereumjs/util": true,
"@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/ethjs>@metamask/ethjs-unit": true,
"@metamask/network-controller>@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/utils": true,
"bn.js": true,
"browserify>buffer": true,
"eslint>fast-deep-equal": true,
"eth-ens-namehash": true
}
},
"@metamask/network-controller>@metamask/controller-utils>@spruceid/siwe-parser": {
"globals": {
"console.error": true,
"console.log": true
},
"packages": {
"@metamask/controller-utils>@spruceid/siwe-parser>apg-js": true,
"@noble/hashes": true
}
},
"@metamask/network-controller>@metamask/eth-json-rpc-infura": {
"globals": {
"setTimeout": true
Expand Down Expand Up @@ -2136,15 +2174,25 @@
},
"packages": {
"@ethereumjs/tx>@ethereumjs/util": true,
"@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/ethjs>@metamask/ethjs-unit": true,
"@metamask/snaps-utils>@metamask/permission-controller>@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/utils": true,
"bn.js": true,
"browserify>buffer": true,
"eslint>fast-deep-equal": true,
"eth-ens-namehash": true
}
},
"@metamask/snaps-utils>@metamask/permission-controller>@metamask/controller-utils>@spruceid/siwe-parser": {
"globals": {
"console.error": true,
"console.log": true
},
"packages": {
"@metamask/controller-utils>@spruceid/siwe-parser>apg-js": true,
"@noble/hashes": true
}
},
"@metamask/snaps-utils>@metamask/permission-controller>@metamask/json-rpc-engine": {
"packages": {
"@metamask/providers>@metamask/rpc-errors": true,
Expand Down Expand Up @@ -2239,6 +2287,7 @@
"@metamask/transaction-controller>nonce-tracker": true,
"@metamask/utils": true,
"bn.js": true,
"browserify>buffer": true,
"eth-method-registry": true,
"fast-json-patch": true,
"lodash": true,
Expand All @@ -2263,15 +2312,25 @@
},
"packages": {
"@ethereumjs/tx>@ethereumjs/util": true,
"@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/ethjs>@metamask/ethjs-unit": true,
"@metamask/transaction-controller>@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/utils": true,
"bn.js": true,
"browserify>buffer": true,
"eslint>fast-deep-equal": true,
"eth-ens-namehash": true
}
},
"@metamask/transaction-controller>@metamask/controller-utils>@spruceid/siwe-parser": {
"globals": {
"console.error": true,
"console.log": true
},
"packages": {
"@metamask/controller-utils>@spruceid/siwe-parser>apg-js": true,
"@noble/hashes": true
}
},
"@metamask/transaction-controller>nonce-tracker": {
"packages": {
"@ethersproject/providers": true,
Expand Down Expand Up @@ -2326,15 +2385,25 @@
},
"packages": {
"@ethereumjs/tx>@ethereumjs/util": true,
"@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/ethjs>@metamask/ethjs-unit": true,
"@metamask/user-operation-controller>@metamask/controller-utils>@spruceid/siwe-parser": true,
"@metamask/utils": true,
"bn.js": true,
"browserify>buffer": true,
"eslint>fast-deep-equal": true,
"eth-ens-namehash": true
}
},
"@metamask/user-operation-controller>@metamask/controller-utils>@spruceid/siwe-parser": {
"globals": {
"console.error": true,
"console.log": true
},
"packages": {
"@metamask/controller-utils>@spruceid/siwe-parser>apg-js": true,
"@noble/hashes": true
}
},
"@metamask/utils": {
"globals": {
"TextDecoder": true,
Expand Down
Loading

0 comments on commit ba27c66

Please sign in to comment.