admin: updated dist files

This commit is contained in:
Richard Moore 2024-02-08 20:27:03 -05:00
parent f02211d055
commit 3a1d175c20
14 changed files with 59 additions and 74 deletions

@ -3,9 +3,10 @@ Change Log
This change log is maintained by `src.ts/_admin/update-changelog.ts` but may also be manually updated. This change log is maintained by `src.ts/_admin/update-changelog.ts` but may also be manually updated.
ethers/v6.11.0 (2024-02-05 19:57) ethers/v6.11.0 (2024-02-08 20:26)
--------------------------------- ---------------------------------
- Allow transaction encoding for inferred type transactions ([f02211d](https://github.com/ethers-io/ethers.js/commit/f02211d055567b51373b5faa2c3dc6efe0523618)).
- Added EIP-4788, receipts root and state root fields to Block ([#4570](https://github.com/ethers-io/ethers.js/issues/4570); [c5f126f](https://github.com/ethers-io/ethers.js/commit/c5f126faf7d826b6a99df0ee578ff3d0ef409381)). - Added EIP-4788, receipts root and state root fields to Block ([#4570](https://github.com/ethers-io/ethers.js/issues/4570); [c5f126f](https://github.com/ethers-io/ethers.js/commit/c5f126faf7d826b6a99df0ee578ff3d0ef409381)).
- Added EIP-4844 fields to Provider classes and formatter ([#4570](https://github.com/ethers-io/ethers.js/issues/4570); [7b4f2c1](https://github.com/ethers-io/ethers.js/commit/7b4f2c1a74db411829b5e8ef758bfa2ee21e5890)). - Added EIP-4844 fields to Provider classes and formatter ([#4570](https://github.com/ethers-io/ethers.js/issues/4570); [7b4f2c1](https://github.com/ethers-io/ethers.js/commit/7b4f2c1a74db411829b5e8ef758bfa2ee21e5890)).
- Assert BrowserProvider receives an EIP-1193 provider to fail early when passing undefined ethereum object ([b69f43b](https://github.com/ethers-io/ethers.js/commit/b69f43bc6f35da881ca7a0c8ccc5fda92edd076d)). - Assert BrowserProvider receives an EIP-1193 provider to fail early when passing undefined ethereum object ([b69f43b](https://github.com/ethers-io/ethers.js/commit/b69f43bc6f35da881ca7a0c8ccc5fda92edd076d)).

28
dist/ethers.js vendored

@ -9709,10 +9709,9 @@ function _parseLegacy(data) {
return tx; return tx;
} }
function _serializeLegacy(tx, sig) { function _serializeLegacy(tx, sig) {
assertArgument(tx.isLegacy(), "internal check failed; !legacy", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
@ -9801,17 +9800,16 @@ function _parseEip1559(data) {
return tx; return tx;
} }
function _serializeEip1559(tx, sig) { function _serializeEip1559(tx, sig) {
assertArgument(tx.isLondon(), "internal check failed; !london", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));
@ -9843,16 +9841,15 @@ function _parseEip2930(data) {
return tx; return tx;
} }
function _serializeEip2930(tx, sig) { function _serializeEip2930(tx, sig) {
assertArgument(tx.isBerlin(), "internal check failed; !berlin", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "recoveryParam")); fields.push(formatNumber(sig.yParity, "recoveryParam"));
@ -9893,19 +9890,18 @@ function _parseEip4844(data) {
return tx; return tx;
} }
function _serializeEip4844(tx, sig) { function _serializeEip4844(tx, sig) {
assertArgument(tx.isCancun(), "internal check failed; !cancun", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
tx.to, (tx.to || ZeroAddress),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
(formatAccessList(tx.accessList)), formatAccessList(tx.accessList || []),
formatNumber(tx.maxFeePerBlobGas, "maxFeePerBlobGas"), formatNumber(tx.maxFeePerBlobGas || 0, "maxFeePerBlobGas"),
formatHashes(tx.blobVersionedHashes, "blobVersionedHashes") formatHashes(tx.blobVersionedHashes || [], "blobVersionedHashes")
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));

2
dist/ethers.js.map vendored

File diff suppressed because one or more lines are too long

2
dist/ethers.min.js vendored

File diff suppressed because one or more lines are too long

28
dist/ethers.umd.js vendored

@ -9715,10 +9715,9 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
return tx; return tx;
} }
function _serializeLegacy(tx, sig) { function _serializeLegacy(tx, sig) {
assertArgument(tx.isLegacy(), "internal check failed; !legacy", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
@ -9807,17 +9806,16 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
return tx; return tx;
} }
function _serializeEip1559(tx, sig) { function _serializeEip1559(tx, sig) {
assertArgument(tx.isLondon(), "internal check failed; !london", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));
@ -9849,16 +9847,15 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
return tx; return tx;
} }
function _serializeEip2930(tx, sig) { function _serializeEip2930(tx, sig) {
assertArgument(tx.isBerlin(), "internal check failed; !berlin", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "recoveryParam")); fields.push(formatNumber(sig.yParity, "recoveryParam"));
@ -9899,19 +9896,18 @@ const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !==
return tx; return tx;
} }
function _serializeEip4844(tx, sig) { function _serializeEip4844(tx, sig) {
assertArgument(tx.isCancun(), "internal check failed; !cancun", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
tx.to, (tx.to || ZeroAddress),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
(formatAccessList(tx.accessList)), formatAccessList(tx.accessList || []),
formatNumber(tx.maxFeePerBlobGas, "maxFeePerBlobGas"), formatNumber(tx.maxFeePerBlobGas || 0, "maxFeePerBlobGas"),
formatHashes(tx.blobVersionedHashes, "blobVersionedHashes") formatHashes(tx.blobVersionedHashes || [], "blobVersionedHashes")
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1 +1 @@
{"version":3,"file":"transaction.d.ts","sourceRoot":"","sources":["../../src.ts/transaction/transaction.ts"],"names":[],"mappings":"AAGA,OAAO,EAAa,SAAS,EAAc,MAAM,oBAAoB,CAAC;AAStE,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACjE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAExD,OAAO,KAAK,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAW5D;;;;GAIG;AACH,MAAM,WAAW,eAAe,CAAC,CAAC,GAAG,MAAM;IACvC;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAErB;;OAEG;IACH,EAAE,CAAC,EAAE,IAAI,GAAG,CAAC,CAAC;IAEd;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,CAAC,CAAC;IAEhB;;OAEG;IACH,KAAK,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAEtB;;OAEG;IACH,QAAQ,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE/B;;OAEG;IACH,QAAQ,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE/B;;OAEG;IACH,oBAAoB,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE3C;;OAEG;IACH,YAAY,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAEnC;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAErB;;OAEG;IACH,KAAK,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE5B;;OAEG;IACH,OAAO,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE9B;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,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"}

@ -100,10 +100,9 @@ function _parseLegacy(data) {
return tx; return tx;
} }
function _serializeLegacy(tx, sig) { function _serializeLegacy(tx, sig) {
(0, index_js_3.assertArgument)(tx.isLegacy(), "internal check failed; !legacy", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
@ -192,17 +191,16 @@ function _parseEip1559(data) {
return tx; return tx;
} }
function _serializeEip1559(tx, sig) { function _serializeEip1559(tx, sig) {
(0, index_js_3.assertArgument)(tx.isLondon(), "internal check failed; !london", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));
@ -234,16 +232,15 @@ function _parseEip2930(data) {
return tx; return tx;
} }
function _serializeEip2930(tx, sig) { function _serializeEip2930(tx, sig) {
(0, index_js_3.assertArgument)(tx.isBerlin(), "internal check failed; !berlin", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "recoveryParam")); fields.push(formatNumber(sig.yParity, "recoveryParam"));
@ -284,19 +281,18 @@ function _parseEip4844(data) {
return tx; return tx;
} }
function _serializeEip4844(tx, sig) { function _serializeEip4844(tx, sig) {
(0, index_js_3.assertArgument)(tx.isCancun(), "internal check failed; !cancun", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
tx.to, (tx.to || addresses_js_1.ZeroAddress),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
(formatAccessList(tx.accessList)), formatAccessList(tx.accessList || []),
formatNumber(tx.maxFeePerBlobGas, "maxFeePerBlobGas"), formatNumber(tx.maxFeePerBlobGas || 0, "maxFeePerBlobGas"),
formatHashes(tx.blobVersionedHashes, "blobVersionedHashes") formatHashes(tx.blobVersionedHashes || [], "blobVersionedHashes")
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));

File diff suppressed because one or more lines are too long

@ -1 +1 @@
{"version":3,"file":"transaction.d.ts","sourceRoot":"","sources":["../../src.ts/transaction/transaction.ts"],"names":[],"mappings":"AAGA,OAAO,EAAa,SAAS,EAAc,MAAM,oBAAoB,CAAC;AAStE,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACjE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAExD,OAAO,KAAK,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAW5D;;;;GAIG;AACH,MAAM,WAAW,eAAe,CAAC,CAAC,GAAG,MAAM;IACvC;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAErB;;OAEG;IACH,EAAE,CAAC,EAAE,IAAI,GAAG,CAAC,CAAC;IAEd;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,CAAC,CAAC;IAEhB;;OAEG;IACH,KAAK,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAEtB;;OAEG;IACH,QAAQ,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE/B;;OAEG;IACH,QAAQ,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE/B;;OAEG;IACH,oBAAoB,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE3C;;OAEG;IACH,YAAY,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAEnC;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAErB;;OAEG;IACH,KAAK,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE5B;;OAEG;IACH,OAAO,CAAC,EAAE,IAAI,GAAG,YAAY,CAAC;IAE9B;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAErB;;OAEG;IACH,SAAS,CAAC,EAAE,IAAI,GAAG,aAAa,CAAC;I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_serializeLegacy(tx, sig) {
assertArgument(tx.isLegacy(), "internal check failed; !legacy", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
@ -189,17 +188,16 @@ function _parseEip1559(data) {
return tx; return tx;
} }
function _serializeEip1559(tx, sig) { function _serializeEip1559(tx, sig) {
assertArgument(tx.isLondon(), "internal check failed; !london", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));
@ -231,16 +229,15 @@ function _parseEip2930(data) {
return tx; return tx;
} }
function _serializeEip2930(tx, sig) { function _serializeEip2930(tx, sig) {
assertArgument(tx.isBerlin(), "internal check failed; !berlin", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.gasPrice, "gasPrice"), formatNumber(tx.gasPrice || 0, "gasPrice"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
(tx.to || "0x"), (tx.to || "0x"),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
formatAccessList(tx.accessList) formatAccessList(tx.accessList || [])
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "recoveryParam")); fields.push(formatNumber(sig.yParity, "recoveryParam"));
@ -281,19 +278,18 @@ function _parseEip4844(data) {
return tx; return tx;
} }
function _serializeEip4844(tx, sig) { function _serializeEip4844(tx, sig) {
assertArgument(tx.isCancun(), "internal check failed; !cancun", "tx", tx);
const fields = [ const fields = [
formatNumber(tx.chainId, "chainId"), formatNumber(tx.chainId, "chainId"),
formatNumber(tx.nonce, "nonce"), formatNumber(tx.nonce, "nonce"),
formatNumber(tx.maxPriorityFeePerGas, "maxPriorityFeePerGas"), formatNumber(tx.maxPriorityFeePerGas || 0, "maxPriorityFeePerGas"),
formatNumber(tx.maxFeePerGas, "maxFeePerGas"), formatNumber(tx.maxFeePerGas || 0, "maxFeePerGas"),
formatNumber(tx.gasLimit, "gasLimit"), formatNumber(tx.gasLimit, "gasLimit"),
tx.to, (tx.to || ZeroAddress),
formatNumber(tx.value, "value"), formatNumber(tx.value, "value"),
tx.data, tx.data,
(formatAccessList(tx.accessList)), formatAccessList(tx.accessList || []),
formatNumber(tx.maxFeePerBlobGas, "maxFeePerBlobGas"), formatNumber(tx.maxFeePerBlobGas || 0, "maxFeePerBlobGas"),
formatHashes(tx.blobVersionedHashes, "blobVersionedHashes") formatHashes(tx.blobVersionedHashes || [], "blobVersionedHashes")
]; ];
if (sig) { if (sig) {
fields.push(formatNumber(sig.yParity, "yParity")); fields.push(formatNumber(sig.yParity, "yParity"));

File diff suppressed because one or more lines are too long

@ -93,7 +93,7 @@
"url": "https://www.buymeacoffee.com/ricmoo" "url": "https://www.buymeacoffee.com/ricmoo"
} }
], ],
"gitHead": "c5f126faf7d826b6a99df0ee578ff3d0ef409381", "gitHead": "f02211d055567b51373b5faa2c3dc6efe0523618",
"homepage": "https://ethers.org", "homepage": "https://ethers.org",
"keywords": [ "keywords": [
"ethereum", "ethereum",