webevm 0.9.1 → 0.10.0
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/README.md +94 -12
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/intrinsic-gas.d.ts +70 -14
- package/dist/intrinsic-gas.d.ts.map +1 -1
- package/dist/intrinsic-gas.js +65 -0
- package/dist/intrinsic-gas.js.map +1 -1
- package/dist/node.d.ts.map +1 -1
- package/dist/node.js +686 -41
- package/dist/node.js.map +1 -1
- package/dist/revm.d.ts +18 -17
- package/dist/revm.d.ts.map +1 -1
- package/dist/revm.js +80 -40
- package/dist/revm.js.map +1 -1
- package/dist/state-manager.d.ts +19 -0
- package/dist/state-manager.d.ts.map +1 -1
- package/dist/state-manager.js +32 -0
- package/dist/state-manager.js.map +1 -1
- package/dist/types.d.ts +39 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/worker-host.d.ts +30 -0
- package/dist/worker-host.d.ts.map +1 -1
- package/dist/worker-host.js +42 -5
- package/dist/worker-host.js.map +1 -1
- package/package.json +2 -2
- package/src/index.ts +1 -0
- package/src/intrinsic-gas.ts +92 -14
- package/src/node.ts +864 -44
- package/src/revm.ts +103 -47
- package/src/state-manager.ts +35 -0
- package/src/types.ts +40 -0
- package/src/worker-host.ts +79 -7
package/README.md
CHANGED
|
@@ -126,6 +126,17 @@ the worker logs it the moment the module loads, AND your `await
|
|
|
126
126
|
createWorkerNode(...)` on the main thread REJECTS with the same text, so the
|
|
127
127
|
mistake reaches the thread you made it on and the thread that was waiting.
|
|
128
128
|
|
|
129
|
+
**Creating the node yourself: `createNode`.** A layer that must take part in creating the node inside the worker (funding accounts at genesis, say, which has to happen before the node exists) passes a node FACTORY:
|
|
130
|
+
|
|
131
|
+
```ts
|
|
132
|
+
exposeNode({
|
|
133
|
+
createEngine: () => createRevmEngine({wasm}), // optional, as before
|
|
134
|
+
createNode: (options) => myCreateNode({...options, accounts: 10}),
|
|
135
|
+
});
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
It is called once per node with the options your main thread passed to `createWorkerNode()`, the engine from `createEngine` already merged in when that is set, and must resolve to a `SlimNode` (typed `(options: NodeOptions) => Promise<SlimNode>`). The node it returns is the one your main thread drives, through the same proxy as always, every member included. Omit it and the worker calls webevm's own `createNode`, exactly as before. A factory that throws or rejects makes `createWorkerNode()` reject with its message; one that is not a function is refused like a bad `createEngine`, logged by the worker AND rejecting `createWorkerNode()` with the same text.
|
|
139
|
+
|
|
129
140
|
**Do not `await` at the top level of a worker module before `exposeNode()`.** A
|
|
130
141
|
worker module that awaits something slower than a microtask (fetching wasm,
|
|
131
142
|
opening a database, `await createRevmEngine(...)`) before it calls `exposeNode()`
|
|
@@ -182,18 +193,24 @@ method-not-found (`-32601`) — it never fakes a result.
|
|
|
182
193
|
| `eth_chainId`, `net_version` | from `chainId` option |
|
|
183
194
|
| `eth_blockNumber` | latest mined block number |
|
|
184
195
|
| `eth_getBlockByNumber`, `eth_getBlockByHash` | header + (optional) full txs; roots are zero unless the node was created with [`computeStateRoot: true`](#state-root-computestateroot-off-by-default-opt-in). `miner`, `mixHash` and `logsBloom` are **real**: the first two are the block's [`blockEnv`](#genesis-pre-state--block-env) coinbase/prevRandao (the same values `COINBASE`/`PREVRANDAO` return to a contract), the third is the OR of the block's receipt blooms, so the standard pre-filter finds the logs that are there. `sha3Uncles`/`transactionsRoot`/`receiptsRoot`/`difficulty`/`totalDifficulty`/`size`/`nonce` are placeholders, and the header's `gasUsed` is **always `0x0`** (read the receipts' `gasUsed`) |
|
|
185
|
-
| `eth_call` | **runs on the [engine](#engine-ethereumjsevm-default-vs-revm-wasm-opt-in)**; pure (never mutates); reverts throw `RpcError(3, 'execution reverted')`; **at the head by default, and at any block in the window with `stateHistory`**, executing against that block's state and block environment (a block below what the node holds is refused, see [State reads at past blocks](#state-reads-at-past-blocks-statehistory)). geth-style **state overrides** (3rd parameter: `balance`, `nonce`, `code`, `state`, `stateDiff`) are applied for that call only, and a malformed or oversized value is `-32602`; any other override field, and **block overrides** (4th parameter), are refused with `-32602` rather than ignored |
|
|
186
|
-
| `eth_estimateGas` | **runs on the [engine](#engine-ethereumjsevm-default-vs-revm-wasm-opt-in)**; the **smallest gas LIMIT at which the request succeeds**, found by re-executing it, with intrinsic gas (incl. EIP-3860) **+ the request's EIP-2930 `accessList`** (2,400/address + 1,900/key, as geth charges it) as the floor. A request that succeeds at what it consumes (a transfer, a plain deployment) gets exactly that, in one extra execution. A request that reverts at any limit gets `RpcError(3, 'execution reverted')` naming the decoded reason and carrying the callee's bytes; one that is simply too big for the allowance gets `-32000 gas required exceeds allowance` (geth's vocabulary), never a number. `gas` on the request is the **cap on the search**, capped in turn by the block gas limit. **At the head by default, and at any block in the window with [`stateHistory`](#state-reads-at-past-blocks-statehistory)**, and takes the same state overrides, like `eth_call` |
|
|
196
|
+
| `eth_call` | **runs on the [engine](#engine-ethereumjsevm-default-vs-revm-wasm-opt-in)**; pure (never mutates); an EIP-7702 `authorizationList` on the request is applied for the call (see [Hardfork](#hardfork-cancun-prague-osaka-default)), and from Prague on a `gas` too small to cover EIP-7623's calldata floor is refused with `-32000`. As on geth, a read is not held to EIP-7825's per-transaction cap on Osaka; reverts throw `RpcError(3, 'execution reverted')`; **at the head by default, and at any block in the window with `stateHistory`**, executing against that block's state and block environment (a block below what the node holds is refused, see [State reads at past blocks](#state-reads-at-past-blocks-statehistory)). geth-style **state overrides** (3rd parameter: `balance`, `nonce`, `code`, `state`, `stateDiff`) are applied for that call only, and a malformed or oversized value is `-32602`; any other override field, and **block overrides** (4th parameter), are refused with `-32602` rather than ignored |
|
|
197
|
+
| `eth_estimateGas` | **runs on the [engine](#engine-ethereumjsevm-default-vs-revm-wasm-opt-in)**; the **smallest gas LIMIT at which the request succeeds**, found by re-executing it, with intrinsic gas (incl. EIP-3860) **+ the request's EIP-2930 `accessList`** (2,400/address + 1,900/key, as geth charges it) as the floor. A request that succeeds at what it consumes (a transfer, a plain deployment) gets exactly that, in one extra execution. A request that reverts at any limit gets `RpcError(3, 'execution reverted')` naming the decoded reason and carrying the callee's bytes; one that is simply too big for the allowance gets `-32000 gas required exceeds allowance` (geth's vocabulary), never a number. `gas` on the request is the **cap on the search**, capped in turn by the block gas limit and, from Osaka on, by EIP-7825's per-transaction cap of 16,777,216. From Prague on the estimate is never below EIP-7623's calldata floor, and an EIP-7702 `authorizationList` is charged (25,000 per entry) and its delegations applied, so the estimate executes the delegated code. **At the head by default, and at any block in the window with [`stateHistory`](#state-reads-at-past-blocks-statehistory)**, and takes the same state overrides, like `eth_call` |
|
|
187
198
|
| `eth_getBalance`, `eth_getCode`, `eth_getStorageAt`, `eth_getTransactionCount` | state reads **at the head by default, and at any block in the window with `stateHistory`** (the values at the end of that block); see [State reads at past blocks](#state-reads-at-past-blocks-statehistory) |
|
|
188
199
|
| `eth_gasPrice`, `eth_maxPriorityFeePerGas` | **constant** (faked fee market — local chain) |
|
|
189
200
|
| `eth_feeHistory` | honours `newestBlock` (a block above the head is `-32000`); the window is clamped at genesis and at 1024 blocks, as geth clamps it, so a chain shorter than `blockCount` returns fewer entries; `baseFeePerGas` is each block's own and `gasUsedRatio` is summed from the block's receipts. `reward` is the **constant** `maxPriorityFeePerGas` (flat fee model), so this is not for real fee prediction |
|
|
190
201
|
| `eth_fillTransaction` | fills missing nonce/gas/fees of a tx request and returns `{tx, raw}` (the `raw` is **unsigned** — sign client-side); viem's `prepareTransactionRequest` uses it. Its gas estimate **runs on the [engine](#engine-ethereumjsevm-default-vs-revm-wasm-opt-in)** |
|
|
191
|
-
| **`eth_sendRawTransaction`** | accepts a **signed** raw tx; mines per `miningConfig`. **Executes and commits on the [engine](#engine-ethereumjsevm-default-vs-revm-wasm-opt-in)**, through its transaction operation |
|
|
202
|
+
| **`eth_sendRawTransaction`** | accepts a **signed** raw tx (types 0, 1 and 2, and type 4 from Prague on); mines per `miningConfig`. Refused with `-32000` before execution, in geth's words: a gas limit below intrinsic gas or (from Prague on) below the calldata floor, one above the block gas limit or (from Osaka on) above 16,777,216, a replayed or future nonce, and a sender that cannot pay. **Executes and commits on the [engine](#engine-ethereumjsevm-default-vs-revm-wasm-opt-in)**, through its transaction operation |
|
|
192
203
|
| **`eth_sendRawTransactionSync`** | the fast path: send + mine + return receipt in one call |
|
|
193
204
|
| `eth_getTransactionReceipt`, `eth_getTransactionByHash` | from the in-memory store |
|
|
194
205
|
| `eth_getLogs` | address + topic filtering over mined logs, by `fromBlock`/`toBlock` or by `blockHash` (EIP-234; an unknown hash is `-32000`, a hash together with a range is `-32602`). An omitted `fromBlock` means block **0** here, where geth means `latest`. Every log (here and inside receipts) carries `blockTimestamp`, its block's timestamp (execution-apis#639). **Perf note:** a full linear scan over all logs per call (O(total_logs), no index/cache) — fine for a local chain |
|
|
195
206
|
| `eth_subscribe`/`eth_unsubscribe` | **`newHeads` only**; prefer `onNewHead()` over comlink |
|
|
196
207
|
| `evm_setBalance` / `evm_setNonce` / `evm_setCode` / `evm_setStorageAt` / `evm_setAccount` | anvil/hardhat-style runtime state cheats (mutate live state with no tx); with `computeStateRoot: true`, `getStateRoot()` reflects them straight away, and the next block's root includes them |
|
|
208
|
+
| `hardhat_setBalance` / `hardhat_setNonce` / `hardhat_setCode` / `hardhat_setStorageAt`, and the same four as `anvil_*` | Hardhat's and anvil's names for the first four state cheats, with exactly their effect, so viem's `setBalance` / `setNonce` / `setCode` / `setStorageAt` test actions in `hardhat` and `anvil` mode work unchanged. Wire shapes are the two nodes': `[address, quantity]`, `[address, code]`, `[address, slot, value]`. They answer what anvil answers under both names: `null` for balance, nonce and code, `true` for storage (Hardhat itself answers `true` for all four; the `evm_*` names still do). Validated where both nodes agree, `-32602` otherwise: a 20-byte address, a balance or slot below 2^256, a nonce below 2^64, code in whole bytes, and a storage value of **exactly 32 bytes** (`evm_setStorageAt` pads a shorter one). A nonce lower than the account's is accepted, as on anvil; Hardhat refuses it |
|
|
209
|
+
| `evm_setNextBlockTimestamp` / `evm_increaseTime` | time cheats: move [the node's clock](#mining), which stamps the next mined block (and so what `TIMESTAMP` reads). Anvil's, hardhat's and ganache's names and wire shapes, so viem's `setNextBlockTimestamp` / `increaseTime` test actions work unchanged. `[timestamp]` stamps the next block, which must be later than the head's (`-32000` otherwise, hardhat's rule; anvil also admits an equal one), returns `null`, and the clock carries on from it. `[seconds]` adds to the clock's offset and returns the total offset as a JSON number. Numbers, decimal and `0x` strings are accepted, up to a uint64 |
|
|
210
|
+
| `evm_mine` | `[]`, `[timestamp]` or `[{timestamp?, blocks?}]` (anvil's and ganache's forms): mine `blocks` (default 1) blocks now, the first with whatever is pending (an empty block under auto mining), the first stamped `timestamp` if given; returns `"0x0"`. The RPC form of `node.mine()` |
|
|
211
|
+
| `anvil_mine` / `hardhat_mine` | `[blocks?, interval?]`, what viem's `mine()` sends: `blocks` (default 1; 0 mines none) blocks now; an `interval` moves the clock on that many seconds a block, 0 letting a block repeat its parent's timestamp, as on anvil (which takes `hardhat_mine` as an alias); returns `null` |
|
|
212
|
+
| `anvil_setBlockTimestampInterval` / `anvil_removeBlockTimestampInterval` | `[seconds]`: every block is its parent's timestamp plus `seconds` (0 repeats it), the wall clock not consulted, so a chain's timestamps do not depend on how fast it ran; a next timestamp still wins for its block; returns `null`. Remove returns whether one was set. Anvil's names (no other dev node has these), which viem's `setBlockTimestampInterval` / `removeBlockTimestampInterval` send in anvil mode |
|
|
213
|
+
| `evm_snapshot` / `evm_revert`, and the same as `anvil_snapshot` / `anvil_revert` | roll the whole chain back. `evm_snapshot` returns an id (a quantity: `"0x0"` first, as on anvil, never reissued; Hardhat starts at `"0x1"`); `evm_revert [id]` restores what a consumer can read as it was (state, blocks and their hashes, receipts, transactions, logs, `getStateRoot()`, the [`stateHistory`](#state-reads-at-past-blocks-statehistory) window) plus the transactions waiting to be mined, and returns `true`, or `false` for an id it does not hold. Reverting **consumes** that snapshot and every one taken after it, as on Hardhat and anvil. The [clock](#mining) follows anvil: a pending next timestamp and the `evm_increaseTime` offset are restored, the interval is kept. With persistence, a revert saves the reverted chain. viem's `snapshot` / `revert` test actions work unchanged in every mode. See [Snapshots](#snapshots-evm_snapshot--evm_revert) for the cost |
|
|
197
214
|
| `evm_sendRawTransactionAs` / `evm_sendRawTransactionSyncAs` | `[raw, from]` — execute as `from`, **skipping ecrecover**. Only exist when `senderMode: 'trusted'`; otherwise a loud `-32601`. See [Sender mode](#sender-mode-recover-authenticated-default-vs-trusted-no-ecrecover) |
|
|
198
215
|
|
|
199
216
|
### Intentionally NOT supported (loud `-32601`)
|
|
@@ -202,6 +219,8 @@ method-not-found (`-32601`) — it never fakes a result.
|
|
|
202
219
|
`eth_sendTransaction`, `eth_accounts`, `eth_sign`, `eth_signTransaction`,
|
|
203
220
|
`personal_*`, `wallet_addEthereumChain`, `wallet_switchEthereumChain`.
|
|
204
221
|
|
|
222
|
+
Need dev accounts anyway (a deploy tool or a test runner expecting anvil's or Hardhat's)? [`@webevm/devnode`](https://github.com/wighawag/webevm/tree/main/packages/devnode#readme) is a separate package that wraps a webevm node: `eth_accounts` answers with the standard test accounts, funded at genesis, and every other method reaches the node unchanged. The core stays execution-only.
|
|
223
|
+
|
|
205
224
|
### Not implemented yet (would `-32601` today)
|
|
206
225
|
|
|
207
226
|
- JSON-RPC batch requests (array payloads); filter polling (`eth_newFilter` etc.);
|
|
@@ -570,14 +589,17 @@ Caveats, all of them real:
|
|
|
570
589
|
([ADR 0014](docs/adr/0014-the-trie-is-derived-from-the-flat-state-not-a-state-manager.md)),
|
|
571
590
|
so `createNode({computeStateRoot: true, engine: revm})` gives the fast engine and a
|
|
572
591
|
real state root together. (It used to throw at construction.)
|
|
573
|
-
- **Only the hardforks it can COST.** The engine serves `berlin
|
|
574
|
-
`
|
|
575
|
-
and `
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
592
|
+
- **Only the hardforks it can COST.** The engine serves `berlin` through
|
|
593
|
+
`osaka`, which covers every fork the node offers ([Hardfork](#hardfork-cancun-prague-osaka-default)),
|
|
594
|
+
and refuses `amsterdam` at construction, naming the reason: its gas model is
|
|
595
|
+
not the one the node's shared intrinsic-gas arithmetic implements, so
|
|
596
|
+
`eth_estimateGas` could hand you a gas limit computed under the wrong rules.
|
|
597
|
+
`prague` and `osaka` were refused until the node applied their gas rules
|
|
598
|
+
itself: the node never hands revm a read below EIP-7623's calldata floor, the
|
|
599
|
+
engine lifts EIP-7825's per-transaction cap on reads as geth does
|
|
600
|
+
(`disableTxGasLimitCap`, `revm-wasm@0.5.0`), and the node recommends no gas
|
|
601
|
+
limit outside either
|
|
602
|
+
([ADR 0015](docs/adr/0015-the-forks-gas-rules-on-the-read-path-are-the-nodes-admission-and-intrinsic-gas-stays-off-the-seam.md)). The pre-Shanghai forks were
|
|
581
603
|
refused too until `revm-wasm@0.3.1`, because both this node and revm charged
|
|
582
604
|
EIP-3860's initcode word cost on forks that predate it; the node now charges
|
|
583
605
|
that term only where `@ethereumjs/common` says the protocol does, and the
|
|
@@ -657,6 +679,24 @@ execution-gas gate in `packages/benchmarks`, which asserts every backend charges
|
|
|
657
679
|
the same gas — two EVMs that agree on every return value can still disagree on
|
|
658
680
|
where execution runs OUT of gas.
|
|
659
681
|
|
|
682
|
+
## Hardfork: `cancun`, `prague`, `osaka` (default)
|
|
683
|
+
|
|
684
|
+
```ts
|
|
685
|
+
const node = await createNode({hardfork: 'prague'}); // default 'osaka'
|
|
686
|
+
```
|
|
687
|
+
|
|
688
|
+
Every block of a node runs one fork, its genesis included. The option takes the forks whose gas rules the node implements end to end, on both engines, and anything else throws at construction (a typo must not quietly become the default):
|
|
689
|
+
|
|
690
|
+
- **`'osaka'` (default)**: Prague's rules plus EIP-7825's per-transaction gas cap of 16,777,216. A transaction asking for more is refused at submit (`transaction gas limit too high`, geth's words) and `eth_estimateGas` never recommends more. `eth_call` is not held to the cap, as on geth: its default budget stays 30,000,000, on both engines (the revm engine lifts the cap on reads with `revm-wasm`'s `disableTxGasLimitCap`). Also `CLZ`, the secp256r1 `P256VERIFY` precompile and the re-priced `MODEXP`.
|
|
691
|
+
- **`'prague'`**: EIP-7702 set-code transactions (type 4) with their authorization lists, executed on both engines; EIP-7623's calldata floor, charged on receipts, refused below at submit (`insufficient gas for floor data gas cost`), and never undercut by `eth_estimateGas`; the BLS12-381 precompiles.
|
|
692
|
+
- **`'cancun'`**: what every node ran before this option existed.
|
|
693
|
+
|
|
694
|
+
Why these rules live in the node rather than on the engine seam: [ADR 0015](docs/adr/0015-the-forks-gas-rules-on-the-read-path-are-the-nodes-admission-and-intrinsic-gas-stays-off-the-seam.md).
|
|
695
|
+
|
|
696
|
+
**What no fork gets here: block-level system operations.** The node builds its own blocks and runs no system call at their start or end, so EIP-4788's beacon-root contract (Cancun) and EIP-2935's block-hash history contract (Prague) are never written, and no EIP-7002 / EIP-7251 requests are produced. `BLOCKHASH` is unaffected at every fork: it reads the node's own blocks.
|
|
697
|
+
|
|
698
|
+
**The fork is part of the chain.** `dumpState()` records it (`hardfork`), and `loadState()` refuses a dump taken on another fork, because a block's hash covers the header fields its fork defines. A dump that predates the field was taken on Cancun. That includes a chain persisted to IndexedDB by an earlier version: a node restored from it comes up only with `hardfork: 'cancun'`, and otherwise fails at construction naming the option, with the stored chain left untouched.
|
|
699
|
+
|
|
660
700
|
## Genesis pre-state + block env
|
|
661
701
|
|
|
662
702
|
- **`initialState`** — full genesis pre-state (`address -> {balance, nonce, code,
|
|
@@ -684,7 +724,49 @@ including the [`stateHistory`](#state-reads-at-past-blocks-statehistory) window.
|
|
|
684
724
|
## Mining
|
|
685
725
|
|
|
686
726
|
`{type:'auto'}` (mine per raw tx — pairs with `eth_sendRawTransactionSync`),
|
|
687
|
-
`{type:'manual'}` (only on `node.mine()`), or `{type:'interval', intervalMs}`.
|
|
727
|
+
`{type:'manual'}` (only on `node.mine()` or `evm_mine`), or `{type:'interval', intervalMs}`.
|
|
728
|
+
|
|
729
|
+
**The clock.** A mined block is stamped with a next timestamp when one is set
|
|
730
|
+
(`evm_setNextBlockTimestamp`, or `evm_mine`'s timestamp), else its parent's
|
|
731
|
+
timestamp plus an interval when one is set (`anvil_setBlockTimestampInterval`),
|
|
732
|
+
else `blockEnv.timestamp` (when pinned) or the wall clock, plus the offset
|
|
733
|
+
`evm_increaseTime` has accumulated. With no time cheat issued that is exactly
|
|
734
|
+
`blockEnv.timestamp` or the wall clock, as before. The methods are anvil's (and
|
|
735
|
+
hardhat's and ganache's where they share them), so a viem test client drives them:
|
|
736
|
+
|
|
737
|
+
```ts
|
|
738
|
+
const test = createTestClient({mode: 'anvil', transport: custom(node)});
|
|
739
|
+
await test.setNextBlockTimestamp({timestamp: 1_900_000_000n});
|
|
740
|
+
await test.mine({blocks: 1});
|
|
741
|
+
await test.increaseTime({seconds: 86_400}); // a day later
|
|
742
|
+
await test.setBlockTimestampInterval({interval: 1}); // reproducible from here on
|
|
743
|
+
```
|
|
744
|
+
|
|
745
|
+
An interval makes a simulated chain reproducible: its timestamps no longer depend
|
|
746
|
+
on how fast it ran. The clock is a setting of the node, not part of `dumpState`;
|
|
747
|
+
`loadState` drops a pending next timestamp. An [`evm_revert`](#snapshots-evm_snapshot--evm_revert) restores a pending next timestamp and the offset and keeps the interval, as anvil does. See [ADR 0016](docs/adr/0016-the-node-has-a-clock-and-time-cheats-move-it.md).
|
|
748
|
+
|
|
749
|
+
## Snapshots (`evm_snapshot` / `evm_revert`)
|
|
750
|
+
|
|
751
|
+
Tests that share one deployment and roll back between cases:
|
|
752
|
+
|
|
753
|
+
```ts
|
|
754
|
+
const test = createTestClient({mode: 'anvil', transport: custom(node)});
|
|
755
|
+
const id = await test.snapshot(); // after the shared deployment
|
|
756
|
+
// ... a test case ...
|
|
757
|
+
await test.revert({id}); // the chain is back where it was; take a new snapshot for the next case
|
|
758
|
+
```
|
|
759
|
+
|
|
760
|
+
A snapshot holds the node's own `dumpState()` and a revert loads it back, so the cost is proportional to the state, not to what changed since. Measured in Chromium (median of five, genesis of N accounts with one storage slot each; `test/snapshot-cost.spec.ts`, recorded in `docs/spikes/snapshots-in-the-core/measurement.md`):
|
|
761
|
+
|
|
762
|
+
| accounts | dump size | snapshot | revert | revert with `computeStateRoot` |
|
|
763
|
+
|---:|---:|---:|---:|---:|
|
|
764
|
+
| 100 | 50 KB | 0.3 ms | 1.3 ms | 10 ms |
|
|
765
|
+
| 1,000 | 0.4 MB | 3 ms | 5 ms | 122 ms |
|
|
766
|
+
| 10,000 | 3.8 MB | 28 ms | 45 ms | 1.46 s |
|
|
767
|
+
| 50,000 | 19 MB | 145 ms | 258 ms | not measured |
|
|
768
|
+
|
|
769
|
+
Each snapshot held keeps its dump in memory until it is consumed. With `computeStateRoot`, a revert rebuilds the derived trie from the restored state, which is what dominates; a node that needs fast reverts over a large state should leave it off. Snapshots are not persisted, and a `loadState` leaves them held.
|
|
688
770
|
|
|
689
771
|
## On comprehensive EVM test fixtures (`ethereum/tests`)
|
|
690
772
|
|
package/dist/index.d.ts
CHANGED
|
@@ -7,6 +7,6 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export { createNode } from './node.js';
|
|
9
9
|
export { createIndexedDBPersistence, createMemoryPersistence, } from './persistence.js';
|
|
10
|
-
export type { SlimNode, ServedPort, NodeOptions, MiningConfig, SenderMode, StateHistoryOptions, Engine, EngineContext, EngineInfo, ReadCallRequest, ReadCallResult, TransactionRequest, TransactionResult, TransactionLog, GenesisAccount, BlockEnv, PersistenceAdapter, RequestArguments, SerializedState, SerializedHistoryBlock, } from './types.js';
|
|
10
|
+
export type { NodeHardfork, SlimNode, ServedPort, NodeOptions, MiningConfig, SenderMode, StateHistoryOptions, Engine, EngineContext, EngineInfo, ReadCallRequest, ReadCallResult, TransactionRequest, TransactionResult, TransactionLog, GenesisAccount, BlockEnv, PersistenceAdapter, RequestArguments, SerializedState, SerializedHistoryBlock, } from './types.js';
|
|
11
11
|
export { RpcError } from './types.js';
|
|
12
12
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAC,UAAU,EAAC,MAAM,WAAW,CAAC;AACrC,OAAO,EACN,0BAA0B,EAC1B,uBAAuB,GACvB,MAAM,kBAAkB,CAAC;AAC1B,YAAY,EACX,QAAQ,EACR,UAAU,EACV,WAAW,EACX,YAAY,EACZ,UAAU,EACV,mBAAmB,EAInB,MAAM,EACN,aAAa,EACb,UAAU,EACV,eAAe,EACf,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,cAAc,EACd,cAAc,EACd,QAAQ,EACR,kBAAkB,EAClB,gBAAgB,EAChB,eAAe,EACf,sBAAsB,GACtB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAC,QAAQ,EAAC,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAC,UAAU,EAAC,MAAM,WAAW,CAAC;AACrC,OAAO,EACN,0BAA0B,EAC1B,uBAAuB,GACvB,MAAM,kBAAkB,CAAC;AAC1B,YAAY,EACX,YAAY,EACZ,QAAQ,EACR,UAAU,EACV,WAAW,EACX,YAAY,EACZ,UAAU,EACV,mBAAmB,EAInB,MAAM,EACN,aAAa,EACb,UAAU,EACV,eAAe,EACf,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,cAAc,EACd,cAAc,EACd,QAAQ,EACR,kBAAkB,EAClB,gBAAgB,EAChB,eAAe,EACf,sBAAsB,GACtB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAC,QAAQ,EAAC,MAAM,YAAY,CAAC"}
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAC,UAAU,EAAC,MAAM,WAAW,CAAC;AACrC,OAAO,EACN,0BAA0B,EAC1B,uBAAuB,GACvB,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAC,UAAU,EAAC,MAAM,WAAW,CAAC;AACrC,OAAO,EACN,0BAA0B,EAC1B,uBAAuB,GACvB,MAAM,kBAAkB,CAAC;AA2B1B,OAAO,EAAC,QAAQ,EAAC,MAAM,YAAY,CAAC;AACpC,6EAA6E;AAC7E,iFAAiF;AACjF,kDAAkD;AAClD,+EAA+E;AAC/E,yCAAyC;AACzC,2DAA2D;AAC3D,iEAAiE;AACjE,kFAAkF;AAClF,qCAAqC;AACrC,mDAAmD"}
|
package/dist/intrinsic-gas.d.ts
CHANGED
|
@@ -48,19 +48,28 @@
|
|
|
48
48
|
* Shanghai, which is precisely the drift this file exists to prevent. See
|
|
49
49
|
* `docs/adr/0008-the-revm-engine-admits-only-hardforks-it-can-cost.md`.
|
|
50
50
|
*
|
|
51
|
-
* THE FORK RANGE THIS FORMULA IS TRUE FOR IS ISTANBUL..
|
|
52
|
-
* AT BOTH SIDES. The node runs Cancun
|
|
53
|
-
* Berlin..
|
|
54
|
-
* measured against the protocol at every admitted fork by the
|
|
55
|
-
* assertions in `test/revm-engine.spec.ts`; the two ends are where the
|
|
56
|
-
* stops being true, so they are what anyone moving the node's hardfork
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
* (
|
|
51
|
+
* THE FORK RANGE THIS FORMULA IS TRUE FOR IS ISTANBUL..OSAKA, AND IT HAS AN END
|
|
52
|
+
* AT BOTH SIDES. The node runs Cancun, Prague or Osaka (`NodeOptions.hardfork`);
|
|
53
|
+
* `webevm/revm` admits Berlin..Osaka, which sits strictly inside that range.
|
|
54
|
+
* Every term above is measured against the protocol at every admitted fork by the
|
|
55
|
+
* clause-(b) assertions in `test/revm-engine.spec.ts`; the two ends are where the
|
|
56
|
+
* formula stops being true, so they are what anyone moving the node's hardfork
|
|
57
|
+
* owes.
|
|
58
|
+
*
|
|
59
|
+
* FROM PRAGUE ON, THREE MORE RULES, AND NONE OF THEM IS A TERM OF THIS FORMULA.
|
|
60
|
+
* EIP-7623's calldata floor ({@link calldataFloorGas}) bounds a transaction's
|
|
61
|
+
* TOTAL from below, EIP-7825's cap ({@link transactionGasLimitCap}, Osaka) bounds
|
|
62
|
+
* its gas LIMIT from above, and EIP-7702's per-authorization charge
|
|
63
|
+
* ({@link authorizationListGas}) is paid only by a transaction that carries an
|
|
64
|
+
* authorization list, which a read request never does. So they sit BESIDE this
|
|
65
|
+
* formula and are applied by the node alone, above the engine seam: the node
|
|
66
|
+
* never hands an engine a read whose total is below the floor, and the one number
|
|
67
|
+
* an engine needs, this one, is unchanged. Moving intrinsic gas
|
|
68
|
+
* onto the seam's read request instead was evaluated and rejected; see
|
|
69
|
+
* `docs/adr/0015-the-forks-gas-rules-on-the-read-path-are-the-nodes-admission-and-intrinsic-gas-stays-off-the-seam.md`.
|
|
70
|
+
* AT AMSTERDAM the formula stops being true (EIP-8037 splits intrinsic gas into
|
|
71
|
+
* two dimensions, EIP-7976 re-prices calldata tokens), which is why that fork is
|
|
72
|
+
* refused by name.
|
|
64
73
|
*
|
|
65
74
|
* BELOW, AT ISTANBUL: the 16 above is EIP-2028's, which shipped in Istanbul, and
|
|
66
75
|
* it is hardcoded here rather than gated. Before Istanbul a non-zero calldata
|
|
@@ -70,7 +79,8 @@
|
|
|
70
79
|
* The term is NOT fork-gated on purpose: no admitted fork predates Istanbul and
|
|
71
80
|
* none can, because a fork in neither of ./revm.ts's two tables is refused by the
|
|
72
81
|
* "no revm spec is known" guard, so a gate would be arithmetic nothing can reach
|
|
73
|
-
* (the
|
|
82
|
+
* (the argument that once kept the EIP-7623 floor out, before a hardfork option
|
|
83
|
+
* made it reachable). What stands in its place
|
|
74
84
|
* is a measurement rather than a comment: the suite measures this term either
|
|
75
85
|
* side of the Istanbul boundary (`petersburg` and `istanbul`), so re-admitting a
|
|
76
86
|
* pre-Istanbul fork turns that measured disagreement into a failing build. If one
|
|
@@ -93,6 +103,52 @@
|
|
|
93
103
|
*/
|
|
94
104
|
import type { Common } from '@ethereumjs/common';
|
|
95
105
|
export declare function intrinsicGas(data: Uint8Array, isCreate: boolean, common: Common): bigint;
|
|
106
|
+
/**
|
|
107
|
+
* EIP-7623 (Prague): THE LEAST A TRANSACTION WITH THIS CALLDATA PAYS, whatever it
|
|
108
|
+
* executes: `21000 + 10 * tokens`, a zero byte being one token and a non-zero byte
|
|
109
|
+
* four. `0n` on a fork without EIP-7623, so a caller can take `max(.., floor)`
|
|
110
|
+
* unconditionally.
|
|
111
|
+
*
|
|
112
|
+
* A FLOOR ON THE TOTAL, NOT A TERM. A transaction is charged
|
|
113
|
+
* `max(intrinsic + execution - refund, floor)`, and its gas LIMIT must be at
|
|
114
|
+
* least the floor before it may start (`INTRINSIC_GAS_TOO_LOW` on
|
|
115
|
+
* `@ethereumjs/vm`, `GasFloorMoreThanGasLimit` on revm,
|
|
116
|
+
* `insufficient gas for floor data gas cost` on geth). The access list does not
|
|
117
|
+
* enter it at Prague or Osaka (EIP-7981, which adds it, is Amsterdam's).
|
|
118
|
+
*
|
|
119
|
+
* Gated on the node's `Common` by `isActivatedEIP(7623)`, for the reason the
|
|
120
|
+
* EIP-3860 term above is: that is the table `runTx` consults when it applies the
|
|
121
|
+
* same floor to a mined transaction.
|
|
122
|
+
*/
|
|
123
|
+
export declare function calldataFloorGas(data: Uint8Array, common: Common): bigint;
|
|
124
|
+
/**
|
|
125
|
+
* EIP-7825 (Osaka): THE LARGEST GAS LIMIT ONE TRANSACTION MAY CARRY, 2^24, or
|
|
126
|
+
* `undefined` on a fork without the cap. A limit above it is refused outright by
|
|
127
|
+
* every party (`@ethereumjs/tx` at construction, revm with
|
|
128
|
+
* `TxGasLimitGreaterThanCap`, geth with `transaction gas limit too high`); it is
|
|
129
|
+
* never trimmed. The node applies it to what it ADMITS and RECOMMENDS: a
|
|
130
|
+
* transaction above it is refused at submit, and `eth_estimateGas` never searches
|
|
131
|
+
* above it. A READ is not held to it, as geth's `eth_call` is not: the default
|
|
132
|
+
* engine's `runCall` never enforced it, and the revm engine lifts it on its reads
|
|
133
|
+
* (`disableTxGasLimitCap`).
|
|
134
|
+
*/
|
|
135
|
+
export declare function transactionGasLimitCap(common: Common): bigint | undefined;
|
|
136
|
+
/**
|
|
137
|
+
* WHAT AN `eth_estimateGas` REQUEST'S EIP-7702 AUTHORIZATION LIST COSTS UP FRONT:
|
|
138
|
+
* 25,000 per entry, the charge a type-4 transaction pays before its first opcode
|
|
139
|
+
* (`@ethereumjs/tx`'s `getIntrinsicGas()` includes it, which is the floor the
|
|
140
|
+
* node refuses a submitted transaction against). The 12,500 refunded for an
|
|
141
|
+
* authority that already exists is NOT subtracted: the estimate over-states by
|
|
142
|
+
* that much, which is the safe direction for a number a client uses as a gas
|
|
143
|
+
* limit.
|
|
144
|
+
*
|
|
145
|
+
* Beside {@link intrinsicGas} rather than inside it for the reason
|
|
146
|
+
* {@link accessListGas} is: the engine seam's read request carries no
|
|
147
|
+
* authorization list, so a term in the shared formula would be subtracted by the
|
|
148
|
+
* revm engine from a figure that never contained it. `0n` for anything that is
|
|
149
|
+
* not an array, so an untyped request cannot make an estimate throw here.
|
|
150
|
+
*/
|
|
151
|
+
export declare function authorizationListGas(authorizationList: unknown): bigint;
|
|
96
152
|
/**
|
|
97
153
|
* WHAT AN `eth_estimateGas` REQUEST'S ACCESS LIST COSTS: 2,400 per address plus
|
|
98
154
|
* 1,900 per storage key, the EIP-2930 charge, added to {@link intrinsicGas} by
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intrinsic-gas.d.ts","sourceRoot":"","sources":["../src/intrinsic-gas.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"intrinsic-gas.d.ts","sourceRoot":"","sources":["../src/intrinsic-gas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsGG;AACH,OAAO,KAAK,EAAC,MAAM,EAAC,MAAM,oBAAoB,CAAC;AAE/C,wBAAgB,YAAY,CAC3B,IAAI,EAAE,UAAU,EAChB,QAAQ,EAAE,OAAO,EACjB,MAAM,EAAE,MAAM,GACZ,MAAM,CAgBR;AAKD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAKzE;AAKD;;;;;;;;;;GAUG;AACH,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAEzE;AAKD;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,oBAAoB,CAAC,iBAAiB,EAAE,OAAO,GAAG,MAAM,CAGvE;AAOD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AACH,wBAAgB,aAAa,CAAC,UAAU,EAAE,OAAO,GAAG,MAAM,CAgBzD"}
|
package/dist/intrinsic-gas.js
CHANGED
|
@@ -16,6 +16,71 @@ export function intrinsicGas(data, isCreate, common) {
|
|
|
16
16
|
}
|
|
17
17
|
return gas;
|
|
18
18
|
}
|
|
19
|
+
/** EIP-7623: what one calldata TOKEN costs under the floor. */
|
|
20
|
+
const TOTAL_COST_FLOOR_PER_TOKEN = 10n;
|
|
21
|
+
/**
|
|
22
|
+
* EIP-7623 (Prague): THE LEAST A TRANSACTION WITH THIS CALLDATA PAYS, whatever it
|
|
23
|
+
* executes: `21000 + 10 * tokens`, a zero byte being one token and a non-zero byte
|
|
24
|
+
* four. `0n` on a fork without EIP-7623, so a caller can take `max(.., floor)`
|
|
25
|
+
* unconditionally.
|
|
26
|
+
*
|
|
27
|
+
* A FLOOR ON THE TOTAL, NOT A TERM. A transaction is charged
|
|
28
|
+
* `max(intrinsic + execution - refund, floor)`, and its gas LIMIT must be at
|
|
29
|
+
* least the floor before it may start (`INTRINSIC_GAS_TOO_LOW` on
|
|
30
|
+
* `@ethereumjs/vm`, `GasFloorMoreThanGasLimit` on revm,
|
|
31
|
+
* `insufficient gas for floor data gas cost` on geth). The access list does not
|
|
32
|
+
* enter it at Prague or Osaka (EIP-7981, which adds it, is Amsterdam's).
|
|
33
|
+
*
|
|
34
|
+
* Gated on the node's `Common` by `isActivatedEIP(7623)`, for the reason the
|
|
35
|
+
* EIP-3860 term above is: that is the table `runTx` consults when it applies the
|
|
36
|
+
* same floor to a mined transaction.
|
|
37
|
+
*/
|
|
38
|
+
export function calldataFloorGas(data, common) {
|
|
39
|
+
if (!common.isActivatedEIP(7623))
|
|
40
|
+
return 0n;
|
|
41
|
+
let tokens = 0n;
|
|
42
|
+
for (const b of data)
|
|
43
|
+
tokens += b === 0 ? 1n : 4n;
|
|
44
|
+
return 21000n + TOTAL_COST_FLOOR_PER_TOKEN * tokens;
|
|
45
|
+
}
|
|
46
|
+
/** EIP-7825 (Osaka): the largest gas limit a single transaction may carry. */
|
|
47
|
+
const MAX_TRANSACTION_GAS_LIMIT = 16777216n;
|
|
48
|
+
/**
|
|
49
|
+
* EIP-7825 (Osaka): THE LARGEST GAS LIMIT ONE TRANSACTION MAY CARRY, 2^24, or
|
|
50
|
+
* `undefined` on a fork without the cap. A limit above it is refused outright by
|
|
51
|
+
* every party (`@ethereumjs/tx` at construction, revm with
|
|
52
|
+
* `TxGasLimitGreaterThanCap`, geth with `transaction gas limit too high`); it is
|
|
53
|
+
* never trimmed. The node applies it to what it ADMITS and RECOMMENDS: a
|
|
54
|
+
* transaction above it is refused at submit, and `eth_estimateGas` never searches
|
|
55
|
+
* above it. A READ is not held to it, as geth's `eth_call` is not: the default
|
|
56
|
+
* engine's `runCall` never enforced it, and the revm engine lifts it on its reads
|
|
57
|
+
* (`disableTxGasLimitCap`).
|
|
58
|
+
*/
|
|
59
|
+
export function transactionGasLimitCap(common) {
|
|
60
|
+
return common.isActivatedEIP(7825) ? MAX_TRANSACTION_GAS_LIMIT : undefined;
|
|
61
|
+
}
|
|
62
|
+
/** EIP-7702: what one authorization costs up front (`PER_EMPTY_ACCOUNT_COST`). */
|
|
63
|
+
const PER_AUTHORIZATION_COST = 25000n;
|
|
64
|
+
/**
|
|
65
|
+
* WHAT AN `eth_estimateGas` REQUEST'S EIP-7702 AUTHORIZATION LIST COSTS UP FRONT:
|
|
66
|
+
* 25,000 per entry, the charge a type-4 transaction pays before its first opcode
|
|
67
|
+
* (`@ethereumjs/tx`'s `getIntrinsicGas()` includes it, which is the floor the
|
|
68
|
+
* node refuses a submitted transaction against). The 12,500 refunded for an
|
|
69
|
+
* authority that already exists is NOT subtracted: the estimate over-states by
|
|
70
|
+
* that much, which is the safe direction for a number a client uses as a gas
|
|
71
|
+
* limit.
|
|
72
|
+
*
|
|
73
|
+
* Beside {@link intrinsicGas} rather than inside it for the reason
|
|
74
|
+
* {@link accessListGas} is: the engine seam's read request carries no
|
|
75
|
+
* authorization list, so a term in the shared formula would be subtracted by the
|
|
76
|
+
* revm engine from a figure that never contained it. `0n` for anything that is
|
|
77
|
+
* not an array, so an untyped request cannot make an estimate throw here.
|
|
78
|
+
*/
|
|
79
|
+
export function authorizationListGas(authorizationList) {
|
|
80
|
+
if (!Array.isArray(authorizationList))
|
|
81
|
+
return 0n;
|
|
82
|
+
return BigInt(authorizationList.length) * PER_AUTHORIZATION_COST;
|
|
83
|
+
}
|
|
19
84
|
/** EIP-2930: what one access-list entry's ADDRESS costs, up front. */
|
|
20
85
|
const ACCESS_LIST_ADDRESS_COST = 2400n;
|
|
21
86
|
/** EIP-2930: what one access-list STORAGE KEY costs, up front. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intrinsic-gas.js","sourceRoot":"","sources":["../src/intrinsic-gas.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"intrinsic-gas.js","sourceRoot":"","sources":["../src/intrinsic-gas.ts"],"names":[],"mappings":"AAyGA,MAAM,UAAU,YAAY,CAC3B,IAAgB,EAChB,QAAiB,EACjB,MAAc;IAEd,IAAI,GAAG,GAAG,MAAO,CAAC;IAClB,gFAAgF;IAChF,0EAA0E;IAC1E,sEAAsE;IACtE,KAAK,MAAM,CAAC,IAAI,IAAI;QAAE,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC;IAChD,IAAI,QAAQ,EAAE,CAAC;QACd,GAAG,IAAI,MAAO,CAAC;QACf,4EAA4E;QAC5E,sEAAsE;QACtE,yEAAyE;QACzE,IAAI,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC,EAAE,CAAC;YACjC,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,GAAG,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC;QACjD,CAAC;IACF,CAAC;IACD,OAAO,GAAG,CAAC;AACZ,CAAC;AAED,+DAA+D;AAC/D,MAAM,0BAA0B,GAAG,GAAG,CAAC;AAEvC;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,UAAU,gBAAgB,CAAC,IAAgB,EAAE,MAAc;IAChE,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC;QAAE,OAAO,EAAE,CAAC;IAC5C,IAAI,MAAM,GAAG,EAAE,CAAC;IAChB,KAAK,MAAM,CAAC,IAAI,IAAI;QAAE,MAAM,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;IAClD,OAAO,MAAO,GAAG,0BAA0B,GAAG,MAAM,CAAC;AACtD,CAAC;AAED,8EAA8E;AAC9E,MAAM,yBAAyB,GAAG,SAAW,CAAC;AAE9C;;;;;;;;;;GAUG;AACH,MAAM,UAAU,sBAAsB,CAAC,MAAc;IACpD,OAAO,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,yBAAyB,CAAC,CAAC,CAAC,SAAS,CAAC;AAC5E,CAAC;AAED,kFAAkF;AAClF,MAAM,sBAAsB,GAAG,MAAO,CAAC;AAEvC;;;;;;;;;;;;;;GAcG;AACH,MAAM,UAAU,oBAAoB,CAAC,iBAA0B;IAC9D,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,iBAAiB,CAAC;QAAE,OAAO,EAAE,CAAC;IACjD,OAAO,MAAM,CAAC,iBAAiB,CAAC,MAAM,CAAC,GAAG,sBAAsB,CAAC;AAClE,CAAC;AAED,sEAAsE;AACtE,MAAM,wBAAwB,GAAG,KAAM,CAAC;AACxC,kEAAkE;AAClE,MAAM,4BAA4B,GAAG,KAAM,CAAC;AAE5C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AACH,MAAM,UAAU,aAAa,CAAC,UAAmB;IAChD,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC;QAAE,OAAO,EAAE,CAAC;IAC1C,IAAI,GAAG,GAAG,EAAE,CAAC;IACb,KAAK,MAAM,KAAK,IAAI,UAAU,EAAE,CAAC;QAChC,gFAAgF;QAChF,oEAAoE;QACpE,8EAA8E;QAC9E,6EAA6E;QAC7E,mBAAmB;QACnB,IAAI,KAAK,KAAK,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ;YAAE,SAAS;QAC1D,GAAG,IAAI,wBAAwB,CAAC;QAChC,MAAM,IAAI,GAAI,KAAiC,CAAC,WAAW,CAAC;QAC5D,IAAI,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC;YACtB,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,4BAA4B,CAAC;IAC5D,CAAC;IACD,OAAO,GAAG,CAAC;AACZ,CAAC"}
|
package/dist/node.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node.d.ts","sourceRoot":"","sources":["../src/node.ts"],"names":[],"mappings":"AAwCA,OAAO,EAIN,KAAK,SAAS,EACd,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"node.d.ts","sourceRoot":"","sources":["../src/node.ts"],"names":[],"mappings":"AAwCA,OAAO,EAIN,KAAK,SAAS,EACd,MAAM,oBAAoB,CAAC;AAwD5B,OAAO,EAGN,KAAK,WAAW,EAIhB,KAAK,QAAQ,EAQb,MAAM,YAAY,CAAC;AAiVpB;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC7B;;;;;;;OAOG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED;;;;;GAKG;AACH,MAAM,WAAW,cAAc;IAC9B,SAAS,EAAE,OAAO,CAAC;IACnB;;;OAGG;IACH,YAAY,EAAE,SAAS,MAAM,EAAE,CAAC;IAChC,kGAAkG;IAClG,SAAS,EAAE,SAAS,GAAG,SAAS,CAAC;IACjC,mFAAmF;IACnF,IAAI,EAAE,SAAS,GAAG,SAAS,CAAC;CAC5B;AAID;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,QAAQ,GAAG,cAAc,CAOjE;AAoGD,wBAAsB,UAAU,CAAC,OAAO,GAAE,WAAgB,GAAG,OAAO,CAAC,QAAQ,CAAC,CAE7E;AAED,0EAA0E;AAC1E,wBAAsB,uBAAuB,CAC5C,OAAO,EAAE,WAAW,EACpB,SAAS,EAAE,aAAa,GACtB,OAAO,CAAC,QAAQ,CAAC,CA0/GnB"}
|