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

[WIP] TheMerge - Kiln #3805

Merged
merged 910 commits into from
May 26, 2022
Merged

[WIP] TheMerge - Kiln #3805

merged 910 commits into from
May 26, 2022

Conversation

MarekM25
Copy link
Contributor

@MarekM25 MarekM25 commented Feb 9, 2022

This branch shouldn't be merged to the master now. The code requires solid cleanup before review.

Build:

git clone --recursive -b kiln https://github.com/NethermindEth/nethermind.git
cd nethermind/src/Nethermind
dotnet build Nethermind.sln -c Release

Running kiln:

cd Nethermind.Runner
dotnet run -c Release -- --config kiln --JsonRpc.Host=0.0.0.0 --JsonRpc.JwtSecretFile=/tmp/jwtsecret

Running against test vectors:

cd Nethermind.Runner
dotnet run -c Release -- --config themerge_kiln_testvectors --Merge.TerminalTotalDifficulty 0

Test vectors: https://notes.ethereum.org/rmVErCfCRPKGqGkUe89-Kg?both

Running - M2 with the transition (TTD = 100)

cd Nethermind.Runner
dotnet run -c Release -- --config themerge_kiln_m2 --Merge.TerminalTotalDifficulty 100

Authentication:

All Nethermind merge configs are configured in this way:
Port 8545 could be a public port for public RPC modules eth, trace etc
Port 8550 is engine without auth
Port 8551 is engine with auth

The default config:

  "JsonRpc": {
    "Enabled": true,
    "Timeout": 20000,
    "Host": "127.0.0.1",
    "Port": 8545,
    "EnabledModules": ["Eth", "Subscribe", "Trace", "TxPool", "Web3", "Personal", "Proof", "Net", "Parity", "Health"],
    "AdditionalRpcUrls": ["http://localhost:8550|http;ws|net;eth;subscribe;engine;web3;client|no-auth", "http://localhost:8551|http;ws|net;eth;subscribe;engine;web3;client"]
  },

The config for secret file:
--JsonRpc.JwtSecretFile with default value keystore/jwt-secret

Connect kiln

https://notes.ethereum.org/qrDBhhydTsyKFmGaBl2COQ?view

@MarekM25 MarekM25 mentioned this pull request Feb 10, 2022
9 tasks
MarekM25 and others added 8 commits May 15, 2022 21:11
# Conflicts:
#	src/Nethermind/Nethermind.Core/BlockInfo.cs
#	src/Nethermind/Nethermind.Merge.Plugin/Handlers/V1/ForkchoiceUpdatedV1Handler.cs
#	src/Nethermind/Nethermind.Network/P2P/Subprotocols/Snap/Messages/ByteCodesMessage.cs
* Configs

* cosmetic

* cosmetic v2
LukaszRozmej and others added 16 commits May 20, 2022 00:12
# Conflicts:
#	src/Nethermind/Nethermind.Consensus.Ethash/EthashDifficultyCalculator.cs
#	src/Nethermind/Nethermind.Consensus.Ethash/EthashPlugin.cs
#	src/Nethermind/Nethermind.Init/Steps/InitializeNetwork.cs
* fix gossip policy according to spec changes

* refactor

* fix test

* refactor

Co-authored-by: Marcin Sobczak <marcindsobczak@gmail.com>
* Add finalized tag and ForkChoiceUpdate method to block tree

* Add unit test for block tree forkChoiceUpdate of finalized hash

* Add finalized update test to EngineModuleTests.V1.cs

* Update finalized block update test

* Add safe tag and metadataDb to BlockTree.cs

* Remove BlockConfirmationManager from ForkchoiceUpdatedV1Handler.cs

* Fix failing EngineModuleTests

* Add missing metadataDb fields to tests

* add json rpc changes

* fix BlockFinderExtensions.cs

* update BlockFinderExtensions.cs

* update BlockTreeTests.cs ForkChoiceUpdated function
* fix gossip policy according to spec changes

* working on tests

* refactor

* fix test

* refactor

* changing the way of handling metadata

* adjusted invalid status to the new spec

* Ignoring old payloads in NewPayloadV1Handler

* changed ConfiguredTerminalBlockNumber

* FinalTotalDifficulty

* fixed tests

* preTTD pivot config

* change workflow?

* added test

* update fcu TryGetBranch

* removed beacon pivot exists check

* remove ignored fcu

* refactor fcu TryGetBranch

* reverted workflow

* fix

* fix test

Co-authored-by: Marcin Sobczak <marcindsobczak@gmail.com>
Co-authored-by: hrugved <whrugved@gmail.com>
* ugly hack for restarts

* more logs

* fix?

* fix build

* fix?

* fix?

* fix

* fix tests

* small changes

* Reverted NLog.config

* one more condition

* fix NLog.config

* multisyncmodeselector logs

* reverted NLog

Co-authored-by: Marcin Sobczak <marcindsobczak@gmail.com>
* Revert Ethash mining

* Don't revert useful things
@LukaszRozmej LukaszRozmej marked this pull request as ready for review May 26, 2022 13:40
@LukaszRozmej LukaszRozmej merged commit 16c75cb into master May 26, 2022
@LukaszRozmej LukaszRozmej deleted the kiln branch May 26, 2022 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants