Aaaaaand... 1559/London EthereumJS releases are out! 🥳 🦀 🌻 (you can take your time with the 15.000 likes)* github.com/ethereumjs/ethere… So what's in it? A short thread: * insider joke for everyone following up here 😎
34
92
4
463
First we have our Common library. You will likely not use this library on its own but you will need it for all other library instantiations since it provides a common view on the network (chain, HF, EIPs).
1
6
Common default HF is still set to "istanbul" and you explicitly have to instantiate with "london" to get all London EIPs activated. It is also possible to just activate single EIPs from London for testing purposes. v2.3.0 out, more in the release notes: github.com/ethereumjs/ethere…
1
1
4
Central regarding the 1559 changes: the Transaction library, which now got a new tx type 2 and a new class called "FeeMarketEIP1559Transaction". You can instantiate a 1559 tx with (the example code can also be found in the release notes):
2
6
Please note the two new properties "maxPriorityFeePerGas" (the priority fee for the miner) and "maxFeePerGas" (the total max fee including the priority fee). In return "gasPrice" is not allowed for tx type 2. v3.2.0 release notes: github.com/ethereumjs/ethere…

May 27, 2021 · 10:18 AM UTC

1
3
Block library releases were a bit boring lately, this changes with the 1559 release v3.3.0 with a new block structure being introduced with the new "baseFeePerGas" field added. 😀 The following example shows how to instantiate a 1559 block:
1
4
The new "calcNextBaseFee()" method shows that the base fee will increase on next block in the example, since the gas used in the block has been greater than half the gas target (you can also try with the equal and smaller-than versions). Release notes: github.com/ethereumjs/ethere…
1
2
Howdy, you can now even create a whole new Blockchain being 1559 compatible with our libraries. Not sure if you want that, but just in case:
1
1
(this blockchain still lacks some blocks to be fair, so relatively boring 😋) Our Blockchain library got an update to v5.3.0 so that e.g. block validation properly works with 1559 blocks: github.com/ethereumjs/ethere…
1
2
And last but not least: the VM. You can now run 1559 blocks and txs against the VM and things like block/tx validation and gas calculation will happen accordingly.
1
1
The VM now also supports the new BASEFEE opcode (EIP-3198) and the reduction in refunds (EIP-3529) regarding the SELFDESTRUCT and SSTORE opcodes. Release notes for v5.4.0: github.com/ethereumjs/ethere…
1
4
Ok, that's it. 🙂 Special thanks to @JochemBrouwer96 and @ralxzryan from the team for all the work done on the London/1559 integration! 🎉 ❤️
1
1
6