Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4844 Browser Readiness Releases #3297

Merged
merged 22 commits into from
Mar 18, 2024
Merged

4844 Browser Readiness Releases #3297

merged 22 commits into from
Mar 18, 2024

Conversation

holgerd77
Copy link
Member

Follow-up on #3261

This is a (relatively big) release round following relatively shortly after the main Dencun hardfork releases.

Biggest addition is the integration of the kzg-wasm library (together with an also browser-compatibility-affecting trie bug) which now makes all 4844 functionality fully browser compatible! 🎉

Copy link

codecov bot commented Mar 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 86.93%. Comparing base (a413006) to head (dfe53cc).

Additional details and impacted files

Impacted file tree graph

Flag Coverage Δ
block 88.43% <ø> (ø)
blockchain 91.61% <ø> (ø)
client 84.85% <ø> (ø)
common 98.43% <ø> (ø)
devp2p 82.12% <ø> (ø)
ethash ∅ <ø> (∅)
evm 74.10% <100.00%> (+0.01%) ⬆️
genesis 99.98% <ø> (ø)
rlp ∅ <ø> (?)
statemanager 77.08% <ø> (ø)
trie 89.98% <ø> (+0.62%) ⬆️
tx 95.08% <ø> (ø)
util 89.34% <ø> (ø)
vm 79.90% <ø> (ø)
wallet 88.35% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

acolytec3
acolytec3 previously approved these changes Mar 13, 2024
Copy link
Contributor

@acolytec3 acolytec3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@holgerd77
Copy link
Member Author

Please do not merge yet, this still needs to be updated with the KZG changes!

Copy link
Member

@jochem-brouwer jochem-brouwer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some small comments


### Other Changes

- Remove internal `_init()` method along EVM/VM constructor refactoring, PRs [#3304](https://github.com/ethereumjs/ethereumjs-monorepo/pull/3304/) and [#3315](https://github.com/ethereumjs/ethereumjs-monorepo/pull/3315)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also in blockchain!

@@ -183,6 +183,7 @@ export interface EVMOpts {
* - [EIP-2537](https://eips.ethereum.org/EIPS/eip-2537) - BLS precompiles (removed in v4.0.0, see latest v3 release)
* - [EIP-2565](https://eips.ethereum.org/EIPS/eip-2565) - ModExp gas cost
* - [EIP-2718](https://eips.ethereum.org/EIPS/eip-2565) - Transaction Types
* - [EIP-2935](https://eips.ethereum.org/EIPS/eip-2935) - Save historical block hashes in state (`experimental`)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aha, I forgot to add this! Thanks :)

@@ -19,7 +19,7 @@ npm install @ethereumjs/evm

This package provides the core Ethereum Virtual Machine (EVM) implementation which is capable of executing EVM-compatible bytecode. The package has been extracted from the [@ethereumjs/vm](https://github.com/ethereumjs/ethereumjs-monorepo/tree/master/packages/vm) package along the VM `v6` release.

**Note:** If you want to work with `EIP-4844` related functionality, you will have additional manual installation steps for the **KZG setup**, see related section below.
**Note:** Starting with the Dencun hardfork `EIP-4844` related functionality will become an integrated part of the EVM functionality with the activation of the point evaluation precompile. It is therefore strongly recommended to _always_ run the EVM with a KZG library installed and initialized, see [KZG Setup](https://github.com/ethereumjs/ethereumjs-monorepo/tree/master/packages/tx/README.md#kzg-setup) for instructions.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(side note, for EVM I think this only matters if you call into the kzg precompile)


#### Trie Node.js Import Bug

Since this fits well also to be placed here relatively prominently for awareness: we had a relatively nasty bug in the `@ethereumjs/trie` library with a `Node.js` web stream import also affecting browser compatibility, see PR [#3280](https://github.com/ethereumjs/ethereumjs-monorepo/pull/3280). This bug has been fixed along with these releases and this library now references the updated trie library version.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you want to add specific Tx changelogs here, we now have getEffectivePriorityFee in tx:

#3295

This returns the "tip" the miner/coinbase will get.

@@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
(modification: no type change headlines) and this project adheres to
[Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## 9.0.3 - 2024-03-05

- Allow optional `trustedSetupPath` for the `initKZG()` method, PR [#3296](https://github.com/ethereumjs/ethereumjs-monorepo/pull/3296)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I think we should maybe mention here that if you want to use kzg-wasm but if you want to use another trustedSetupPath (so another trusted setup than the official one), then this is not possible with kzg-wasm. (Not sure if we throw if you try to initKzg the kzg-wasm with this optional path param..? I don't think so? Might be confusing for the end user if they try this.)

Copy link
Member

@jochem-brouwer jochem-brouwer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM assuming CI passes

@holgerd77 holgerd77 merged commit 48e6a30 into master Mar 18, 2024
36 checks passed
@holgerd77 holgerd77 deleted the new-releases branch March 18, 2024 12:21
@holgerd77
Copy link
Member Author

Just published the following releases on npm:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants