-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Upgrade ethereumjs components for VM v5 #1337
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just posting the progress so far
packages/hardhat-core/src/internal/hardhat-network/jsonrpc/client.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/jsonrpc/types.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/TxPool.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/fork/ForkStateManager.ts
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/fork/ForkStateManager.ts
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/fork/ForkStateManager.ts
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/fork/ForkTransaction.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/test/internal/hardhat-network/provider/HardhatBlockchain.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/test/internal/hardhat-network/provider/HardhatBlockchain.ts
Outdated
Show resolved
Hide resolved
Leaving this for tonight... there are still 3 test failures that am unsure about the cause of or remedy for:
Something's not right. |
packages/hardhat-core/src/internal/hardhat-network/provider/node.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/types/PBlockchain.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/utils/fakeTransaction.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll continue this later today
packages/hardhat-core/src/internal/hardhat-network/provider/BlockchainData.ts
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/fork/ForkTransaction.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, I forgot to submit these comments yesterday
packages/hardhat-core/src/internal/hardhat-network/provider/input.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/fork/ForkTransaction.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/fork/ForkTransaction.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/node.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/output.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/types/PBlockchain.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/utils/makeCommon.ts
Outdated
Show resolved
Hide resolved
packages/hardhat-core/src/internal/hardhat-network/provider/modules/logger.ts
Outdated
Show resolved
Hide resolved
This is a common interface for HardhatBlockchain and ForkBlockchain, that inherits BlockchainInterface (from `@ethereumjs/blockchain`) and adds some common methods that are used in the node.
Thanks so much @fvictorio for all those fixes!!! (Sorry this needed so much additional work) Thanks @alcuadrado 😄 |
This is some initial work migrating hardhat to the new ethereumjs stack. Very WIP 😄 .
Main areas of (real) test failure are forking related, also some TxPool and mining stuff. However, atm almost all provider tests fail due to issue with proposed fix at ethereumjs/ethereumjs-monorepo#1153.
(If you want to see what the actual state of this PR is, you'd need to implement that change locally in your node_modules.)
Summary:
new
to create objects, and their internal properties are immutable. Have left comments in the code where this is presenting difficulties. One place is here.Resources
TODO
Integrate EIP selection into network config, so users can toggle EIPs on/off at will.(We won't do this right now)Major areas of test failure
node#mineBlock (transaction is not signed)TxPool (transaction is not signed)ForkedBlockchain (6 failing )ForkedProvider: ( 1 failing )All stack traces tests (This transaction is not signed)NB: There are scattered single failures in other parts of the test suite (usually just one or two). FSM tests all pass.
Have left some comments in the code describing rationale for misc changes - apologies for doing this directly in the files. I wanted to keep notes as I went through rather than forget to leave notes in GH when opening the PR. Most of these will need to be removed.
Obviously there's still a lot to do (plus some things are done incorrectly) Am just hoping to get the "chore" part of this over the fence so the trickier parts can be fixed by smart people here :)
Please lmk/advise at your leisure about how to proceed and if you have questions.