@metamask-previews/transaction-controller 62.5.0-preview-267e79c3 → 62.6.0-preview-d2037635

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ### Fixed
11
+
12
+ - Include pending authorizations in nonce calculation ([#7446](https://github.com/MetaMask/core/pull/7446))
13
+
14
+ ## [62.6.0]
15
+
10
16
  ### Added
11
17
 
12
18
  - Add `estimateGasBatch` function and messenger action to estimate gas for batch transactions ([#7405](https://github.com/MetaMask/core/pull/7405))
@@ -16,6 +22,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
16
22
  - Ignores transactions with future nonce.
17
23
  - Threshold determined by feature flag.
18
24
 
25
+ ### Changed
26
+
27
+ - Throw with more specific error message if publish fails ([#7418](https://github.com/MetaMask/core/pull/7418))
28
+
19
29
  ### Fixed
20
30
 
21
31
  - Prevent `TransactionController:transactionApproved` event firing if keyring throws during signing ([#7410](https://github.com/MetaMask/core/pull/7410))
@@ -2022,7 +2032,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2022
2032
 
2023
2033
  All changes listed after this point were applied to this package following the monorepo conversion.
2024
2034
 
2025
- [Unreleased]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@62.5.0...HEAD
2035
+ [Unreleased]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@62.6.0...HEAD
2036
+ [62.6.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@62.5.0...@metamask/transaction-controller@62.6.0
2026
2037
  [62.5.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@62.4.0...@metamask/transaction-controller@62.5.0
2027
2038
  [62.4.0]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@62.3.1...@metamask/transaction-controller@62.4.0
2028
2039
  [62.3.1]: https://github.com/MetaMask/core/compare/@metamask/transaction-controller@62.3.0...@metamask/transaction-controller@62.3.1
@@ -1755,13 +1755,20 @@ async function _TransactionController_approveTransaction(transactionId, traceCon
1755
1755
  clearNonceLock?.();
1756
1756
  }
1757
1757
  }, _TransactionController_publishTransaction = async function _TransactionController_publishTransaction(ethQuery, transactionMeta, { skipSubmitHistory } = {}) {
1758
- const transactionHash = await (0, controller_utils_1.query)(ethQuery, 'sendRawTransaction', [
1759
- transactionMeta.rawTx,
1760
- ]);
1761
- if (skipSubmitHistory !== true) {
1762
- __classPrivateFieldGet(this, _TransactionController_instances, "m", _TransactionController_updateSubmitHistory).call(this, transactionMeta, transactionHash);
1758
+ try {
1759
+ const transactionHash = await (0, controller_utils_1.query)(ethQuery, 'sendRawTransaction', [
1760
+ transactionMeta.rawTx,
1761
+ ]);
1762
+ if (skipSubmitHistory !== true) {
1763
+ __classPrivateFieldGet(this, _TransactionController_instances, "m", _TransactionController_updateSubmitHistory).call(this, transactionMeta, transactionHash);
1764
+ }
1765
+ return transactionHash;
1766
+ }
1767
+ catch (error) {
1768
+ const errorObject = error;
1769
+ const errorMessage = errorObject?.data?.message ?? errorObject?.message ?? String(error);
1770
+ throw new Error(errorMessage);
1763
1771
  }
1764
- return transactionHash;
1765
1772
  }, _TransactionController_rejectTransaction = function _TransactionController_rejectTransaction(transactionId, actionId, error) {
1766
1773
  const transactionMeta = __classPrivateFieldGet(this, _TransactionController_instances, "m", _TransactionController_getTransaction).call(this, transactionId);
1767
1774
  if (!transactionMeta) {