Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into disable-txpool
Browse files Browse the repository at this point in the history
# Conflicts:
#	src/Nethermind/Nethermind.Init/Steps/InitializeBlockchain.cs
  • Loading branch information
LukaszRozmej committed Oct 10, 2024
2 parents 53b82a0 + 7ef9398 commit e1a7e38
Show file tree
Hide file tree
Showing 759 changed files with 42,191 additions and 30,222 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/build-tools.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Build tools

on:
merge_group:
types: [checks_requested]
pull_request:
branches: [master]
push:
branches: [master]

jobs:
build:
name: Build
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config: [release]
project:
- docgen/DocGen.sln
- HiveCompare/HiveCompare.sln
- HiveConsensusWorkflowGenerator/HiveConsensusWorkflowGenerator.csproj
- Nethermind.Tools.Kute/Nethermind.Tools.Kute.csproj
- SendBlobs/SendBlobs.sln
- TxParser/TxParser.csproj
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up .NET
uses: actions/setup-dotnet@v4
- name: Build ${{ matrix.project }}
working-directory: tools
run: dotnet build ./${{ matrix.project }} -c ${{ matrix.config }}
8 changes: 4 additions & 4 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,19 @@ jobs:
language: ['csharp']
steps:
- name: Check out repository
uses: actions/checkout@v4
uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 #v4.2.0
with:
submodules: true
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@5618c9fc1e675841ca52c1c6b1304f5255a905a0 #v2.19.0
with:
languages: ${{ matrix.language }}
- name: Set up .NET
uses: actions/setup-dotnet@v4
uses: actions/setup-dotnet@6bd8b7f7774af54e05809fcc5431931b3eb1ddee #v4.0.1
- name: Build Nethermind
working-directory: src/Nethermind
run: dotnet build Nethermind.sln -c release
- name: Perform CodeQL analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@5618c9fc1e675841ca52c1c6b1304f5255a905a0 #v2.19.0
with:
category: '/language:${{ matrix.language }}'
1 change: 1 addition & 0 deletions .github/workflows/nethermind-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ jobs:
- Nethermind.Overseer.Test
- Nethermind.Runner.Test
- Nethermind.Serialization.Ssz.Test
- Nethermind.Shutter.Test
- Nethermind.Sockets.Test
- Nethermind.Specs.Test
- Nethermind.State.Test
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sync-supported-chains.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ jobs:
- name: Setup Go environment
uses: actions/setup-go@v5
with:
go-version: '1.21.0'
go-version: 'stable'
check-latest: true
cache: true

Expand Down
2 changes: 1 addition & 1 deletion src/Nethermind/Chains/base-mainnet.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"eip2930Transition": "0x0",
"eip1559Transition": "0x0",
"eip1559FeeCollectorTransition": "0x0",
"eip1559FeeCollector": "0x4200000000000000000000000000000000000019",
"feeCollector": "0x4200000000000000000000000000000000000019",
"eip1559ElasticityMultiplier": "0x6",
"eip1559BaseFeeMaxChangeDenominator": "0x32",
"eip3198Transition": "0x0",
Expand Down
2 changes: 1 addition & 1 deletion src/Nethermind/Chains/base-sepolia.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"eip2930Transition": "0x0",
"eip1559Transition": "0x0",
"eip1559FeeCollectorTransition": "0x0",
"eip1559FeeCollector": "0x4200000000000000000000000000000000000019",
"feeCollector": "0x4200000000000000000000000000000000000019",
"eip1559ElasticityMultiplier": "0xa",
"eip1559BaseFeeMaxChangeDenominator": "0x32",
"eip3198Transition": "0x0",
Expand Down
3 changes: 2 additions & 1 deletion src/Nethermind/Chains/chiado.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
"eip3529Transition": "0x0",
"eip3541Transition": "0x0",
"eip1559Transition": "0x0",
"beaconChainGenesisTimestamp": "0x6343ee4c",
"eip3651TransitionTimestamp": "0x646e0e4c",
"eip3855TransitionTimestamp": "0x646e0e4c",
"eip3860TransitionTimestamp": "0x646e0e4c",
Expand All @@ -75,7 +76,7 @@
"eip6780TransitionTimestamp": "0x65ba8e4c",
"eip1559BaseFeeMaxChangeDenominator": "0x8",
"eip1559ElasticityMultiplier": "0x2",
"eip1559FeeCollector": "0x1559000000000000000000000000000000000000",
"feeCollector": "0x1559000000000000000000000000000000000000",
"eip1559FeeCollectorTransition": 0,
"eip4844BlobGasPriceUpdateFraction": "0x10fafa",
"eip4844MaxBlobGasPerBlock": "0x40000",
Expand Down
1 change: 1 addition & 0 deletions src/Nethermind/Chains/foundation.json
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,7 @@
"eip3198Transition": "0xC5D488",
"eip3529Transition": "0xC5D488",
"eip3541Transition": "0xC5D488",
"beaconChainGenesisTimestamp": "0x5fc63057",
"eip3651TransitionTimestamp": "0x64373057",
"eip3855TransitionTimestamp": "0x64373057",
"eip3860TransitionTimestamp": "0x64373057",
Expand Down
3 changes: 2 additions & 1 deletion src/Nethermind/Chains/gnosis.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@
"eip3529Transition": 19040000,
"eip3541Transition": 19040000,
"eip1559Transition": 19040000,
"beaconChainGenesisTimestamp": "0x61b10dbc",
"eip3651TransitionTimestamp": "0x64c8edbc",
"eip3855TransitionTimestamp": "0x64c8edbc",
"eip3860TransitionTimestamp": "0x64c8edbc",
Expand All @@ -82,7 +83,7 @@
"eip1559BaseFeeMaxChangeDenominator": "0x8",
"eip1559ElasticityMultiplier": "0x2",
"eip1559BaseFeeInitialValue": "0x3b9aca00",
"eip1559FeeCollector": "0x6BBe78ee9e474842Dbd4AB4987b3CeFE88426A92",
"feeCollector": "0x6BBe78ee9e474842Dbd4AB4987b3CeFE88426A92",
"eip1559FeeCollectorTransition": 19040000,
"eip4844BlobGasPriceUpdateFraction": "0x10fafa",
"eip4844MaxBlobGasPerBlock": "0x40000",
Expand Down
76 changes: 32 additions & 44 deletions src/Nethermind/Chains/hive.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"eip155Transition": "0x0",
"maxCodeSizeTransition": "0x0",
"maxCodeSize": 24576,
"maximumExtraDataSize": 102400,
"maximumExtraDataSize": "0x400",
"eip140Transition": "0x0",
"eip211Transition": "0x0",
"eip214Transition": "0x0",
Expand All @@ -51,57 +51,45 @@
"eip3529Transition": "0x0",
"eip3541Transition": "0x0",
"eip3198Transition": "0x0",
"MergeForkIdTransition": "0x64",
"networkID": "0x7",
"chainID": "0x7"
"eip3651TransitionTimestamp": "0x0",
"eip3855TransitionTimestamp": "0x0",
"eip3860TransitionTimestamp": "0x0",
"eip4895TransitionTimestamp": "0x0",
"eip4844TransitionTimestamp": "0x0",
"eip4788TransitionTimestamp": "0x0",
"eip1153TransitionTimestamp": "0x0",
"eip5656TransitionTimestamp": "0x0",
"eip6780TransitionTimestamp": "0x0",
"eip7702TransitionTimestamp": "0x0",
"chainID": "0x1"
},
"genesis": {
"seal": {
"ethereum": {
"nonce": "0x0000000000000000"
"nonce": "0x0000000000000000",
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000"
}
},
"difficulty": "0x30000",
"difficulty": "0x00",
"author": "0x0000000000000000000000000000000000000000",
"timestamp": "0x1234",
"extraData": "0x0000000000000000000000000000000000000000000000000000000000000000658bdf435d810c91414ec09147daa6db624063790000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"gasLimit": "0x2fefd8"
"timestamp": "0x00",
"parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"extraData": "0x00",
"gasLimit": "0x016345785d8a0000",
"baseFeePerGas": "0x07"
},
"accounts": {
"0xcf49fda3be353c69b41ed96333cd24302da4556f": {
"balance": "0x123450000000000000000"
},
"0x0161e041aad467a890839d5b08b138c1e6373072": {
"balance": "0x123450000000000000000"
},
"0x87da6a8c6e9eff15d703fc2773e32f6af8dbe301": {
"balance": "0x123450000000000000000"
},
"0xb97de4b8c857e4f6bc354f226dc3249aaee49209": {
"balance": "0x123450000000000000000"
},
"0xc5065c9eeebe6df2c2284d046bfc906501846c51": {
"balance": "0x123450000000000000000"
},
"0x0000000000000000000000000000000000000314": {
"balance": "0x0",
"code": "0x60606040526000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff168063a223e05d1461006a578063abd1a0cf1461008d578063abfced1d146100d4578063e05c914a14610110578063e6768b451461014c575b610000565b346100005761007761019d565b6040518082815260200191505060405180910390f35b34610000576100be600480803573ffffffffffffffffffffffffffffffffffffffff169060200190919050506101a3565b6040518082815260200191505060405180910390f35b346100005761010e600480803573ffffffffffffffffffffffffffffffffffffffff169060200190919080359060200190919050506101ed565b005b346100005761014a600480803590602001909190803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610236565b005b346100005761017960048080359060200190919080359060200190919080359060200190919050506103c4565b60405180848152602001838152602001828152602001935050505060405180910390f35b60005481565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490505b919050565b80600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b5050565b7f6031a8d62d7c95988fa262657cd92107d90ed96e08d8f867d32f26edfe85502260405180905060405180910390a17f47e2689743f14e97f7dcfa5eec10ba1dff02f83b3d1d4b9c07b206cbbda66450826040518082815260200191505060405180910390a1817fa48a6b249a5084126c3da369fbc9b16827ead8cb5cdc094b717d3f1dcd995e2960405180905060405180910390a27f7890603b316f3509577afd111710f9ebeefa15e12f72347d9dffd0d65ae3bade81604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390a18073ffffffffffffffffffffffffffffffffffffffff167f7efef9ea3f60ddc038e50cccec621f86a0195894dc0520482abf8b5c6b659e4160405180905060405180910390a28181604051808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060405180910390a05b5050565b6000600060008585859250925092505b935093509390505600a165627a7a72305820aaf842d0d0c35c45622c5263cbb54813d2974d3999c8c38551d7c613ea2bc1170029",
"storage": {
"0x0000000000000000000000000000000000000000000000000000000000000000": "0x1234",
"0x6661e9d6d8b923d5bbaab1b96e1dd51ff6ea2a93520fdc9eb75d059238b8c5e9": "0x01"
}
},
"0x0000000000000000000000000000000000000315": {
"balance": "0x9999999999999999999999999999999",
"code": "0x60606040526000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff168063ef2769ca1461003e575b610000565b3461000057610078600480803573ffffffffffffffffffffffffffffffffffffffff1690602001909190803590602001909190505061007a565b005b8173ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051809050600060405180830381858888f1935050505015610106578173ffffffffffffffffffffffffffffffffffffffff167f30a3c50752f2552dcc2b93f5b96866280816a986c0c0408cb6778b9fa198288f826040518082815260200191505060405180910390a25b5b50505600a165627a7a72305820637991fabcc8abad4294bf2bb615db78fbec4edff1635a2647d3894e2daf6a610029"
},
"0x0000000000000000000000000000000000000316": {
"balance": "0x0",
"code": "0x444355"
},
"0x0000000000000000000000000000000000000317": {
"balance": "0x0",
"code": "0x600160003555"
"0x000f3df6d732807ef1319fb7b8bb8522d0beac02": {
"nonce": "0x01",
"balance": "0x00",
"code": "0x3373fffffffffffffffffffffffffffffffffffffffe14604d57602036146024575f5ffd5b5f35801560495762001fff810690815414603c575f5ffd5b62001fff01545f5260205ff35b5f5ffd5b62001fff42064281555f359062001fff015500",
"storage": {}
},
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b": {
"nonce": "0x00",
"balance": "0x1d6329f1c35ca4bfabb9f5610000000000",
"code": "0x",
"storage": {}
},
"0x0000000000000000000000000000000000000001": {
"builtin": {
Expand Down Expand Up @@ -206,4 +194,4 @@
}
}
}
}
}
1 change: 1 addition & 0 deletions src/Nethermind/Chains/holesky.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
"eip3198Transition": "0x0",
"eip3529Transition": "0x0",
"eip3541Transition": "0x0",
"beaconChainGenesisTimestamp": "0x65156994",
"eip3651TransitionTimestamp": "0x6516eac0",
"eip3855TransitionTimestamp": "0x6516eac0",
"eip3860TransitionTimestamp": "0x6516eac0",
Expand Down
2 changes: 1 addition & 1 deletion src/Nethermind/Chains/op-mainnet.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"eip2930Transition": "0x3C45B0",
"eip1559Transition": "0x645C277",
"eip1559FeeCollectorTransition": "0x645C277",
"eip1559FeeCollector": "0x4200000000000000000000000000000000000019",
"feeCollector": "0x4200000000000000000000000000000000000019",
"eip1559ElasticityMultiplier": "0x6",
"eip1559BaseFeeMaxChangeDenominator": "0x32",
"eip3198Transition": "0x645C277",
Expand Down
2 changes: 1 addition & 1 deletion src/Nethermind/Chains/op-sepolia.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"eip2930Transition": "0x0",
"eip1559Transition": "0x0",
"eip1559FeeCollectorTransition": "0x0",
"eip1559FeeCollector": "0x4200000000000000000000000000000000000019",
"feeCollector": "0x4200000000000000000000000000000000000019",
"eip1559ElasticityMultiplier": "0x6",
"eip1559BaseFeeMaxChangeDenominator": "0x32",
"eip3198Transition": "0x0",
Expand Down
2 changes: 1 addition & 1 deletion src/Nethermind/Chains/poacore.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
"eip1559BaseFeeInitialValue": "0x3b9aca00",
"eip1559BaseFeeMinValue": "0x2540be400",
"eip1559BaseFeeMinValueTransition": 24199500,
"eip1559FeeCollector": "0x517F3AcfF3aFC2fb45e574718bca6F919b798e10",
"feeCollector": "0x517F3AcfF3aFC2fb45e574718bca6F919b798e10",
"eip1559FeeCollectorTransition": 24090200
},
"genesis": {
Expand Down
1 change: 1 addition & 0 deletions src/Nethermind/Chains/sepolia.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
"eip3541Transition": "0x0",
"terminalTotalDifficulty": "3C6568F12E8000",
"mergeForkIdTransition": "0x1A7ACB",
"beaconChainGenesisTimestamp": "0x62b07d60",
"eip4895TransitionTimestamp": "0x63FD7D60",
"eip3855TransitionTimestamp": "0x63FD7D60",
"eip3651TransitionTimestamp": "0x63FD7D60",
Expand Down
13 changes: 7 additions & 6 deletions src/Nethermind/Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
<PackageVersion Include="FastEnum" Version="1.8.0" />
<PackageVersion Include="FluentAssertions" Version="6.12.0" />
<PackageVersion Include="FluentAssertions.Json" Version="6.1.0" />
<PackageVersion Include="Google.Protobuf" Version="3.27.2" />
<PackageVersion Include="Google.Protobuf.Tools" Version="3.27.2" />
<PackageVersion Include="Google.Protobuf" Version="3.28.0" />
<PackageVersion Include="Google.Protobuf.Tools" Version="3.28.0" />
<PackageVersion Include="Grpc" Version="2.46.6" />
<PackageVersion Include="Grpc.Tools" Version="2.65.0" />
<PackageVersion Include="HexMate" Version="0.0.3" />
Expand All @@ -44,22 +44,23 @@
<PackageVersion Include="Microsoft.IO.RecyclableMemoryStream" Version="3.0.1" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.10.0" />
<PackageVersion Include="Microsoft.VisualStudio.Azure.Containers.Tools.Targets" Version="1.21.0" />
<PackageVersion Include="Nethermind.Crypto.Bls" Version="1.0.2" />
<PackageVersion Include="Nethermind.Crypto.Bls" Version="1.0.3" />
<PackageVersion Include="Nethermind.Crypto.Pairings" Version="1.1.1" />
<PackageVersion Include="Nethermind.Crypto.SecP256k1" Version="1.2.2" />
<PackageVersion Include="Nethermind.DotNetty.Buffers" Version="1.0.1" />
<PackageVersion Include="Nethermind.DotNetty.Handlers" Version="1.0.1" />
<PackageVersion Include="Nethermind.DotNetty.Transport" Version="1.0.1" />
<PackageVersion Include="Nethermind.Gmp" Version="1.0.1" />
<PackageVersion Include="Nethermind.Libp2p" Version="1.0.0-preview.33" />
<PackageVersion Include="Nethermind.Numerics.Int256" Version="1.2.0" />
<PackageVersion Include="Nito.Collections.Deque" Version="1.2.1" />
<PackageVersion Include="NLog" Version="5.3.2" />
<PackageVersion Include="NLog.Targets.Seq" Version="4.0.1" />
<PackageVersion Include="NonBlocking" Version="2.1.2" />
<PackageVersion Include="NSubstitute" Version="5.1.0" />
<PackageVersion Include="NUnit" Version="3.14.0" />
<PackageVersion Include="NUnit.Analyzers" Version="3.9.0" />
<PackageVersion Include="NUnit3TestAdapter" Version="4.5.0" />
<PackageVersion Include="NUnit" Version="4.2.2" />
<PackageVersion Include="NUnit.Analyzers" Version="4.3.0" />
<PackageVersion Include="NUnit3TestAdapter" Version="4.6.0" />
<PackageVersion Include="Open.NAT.Core" Version="2.1.0.5" />
<PackageVersion Include="PierTwo.Lantern.Discv5.WireProtocol" Version="1.0.0-preview.4" />
<PackageVersion Include="Polly" Version="8.4.1" />
Expand Down
2 changes: 1 addition & 1 deletion src/Nethermind/Ethereum.Abi.Test/Tests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public void Test_abi_encoding()
}
catch (IOException)
{
TestContext.WriteLine($"Could not find test in {potentialLocation}");
TestContext.Out.WriteLine($"Could not find test in {potentialLocation}");
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,20 @@
using Ethereum.Test.Base;
using NUnit.Framework;

namespace Ethereum.Blockchain.Legacy.Test
namespace Ethereum.Blockchain.Legacy.Test;

[Parallelizable(ParallelScope.All)]
public class ArgsZeroOneBalanaceTests : GeneralStateTestBase
{
[TestFixture]
[Parallelizable(ParallelScope.All)]
public class ArgsZeroOneBalanaceTests : GeneralStateTestBase
[TestCaseSource(nameof(LoadTests))]
public void Test(GeneralStateTest test)
{
[TestCaseSource(nameof(LoadTests))]
public void Test(GeneralStateTest test)
{
Assert.True(RunTest(test).Pass);
}
Assert.That(RunTest(test).Pass, Is.True);
}

public static IEnumerable<GeneralStateTest> LoadTests()
{
var loader = new TestsSourceLoader(new LoadLegacyGeneralStateTestsStrategy(), "stArgsZeroOneBalance");
return (IEnumerable<GeneralStateTest>)loader.LoadTests();
}
public static IEnumerable<GeneralStateTest> LoadTests()
{
var loader = new TestsSourceLoader(new LoadLegacyGeneralStateTestsStrategy(), "stArgsZeroOneBalance");
return (IEnumerable<GeneralStateTest>)loader.LoadTests();
}
}
26 changes: 12 additions & 14 deletions src/Nethermind/Ethereum.Blockchain.Legacy.Test/AttackTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,20 @@
using Ethereum.Test.Base;
using NUnit.Framework;

namespace Ethereum.Blockchain.Legacy.Test
namespace Ethereum.Blockchain.Legacy.Test;

[Parallelizable(ParallelScope.All)]
public class AttackTests : GeneralStateTestBase
{
[TestFixture]
[Parallelizable(ParallelScope.All)]
public class AttackTests : GeneralStateTestBase
[TestCaseSource(nameof(LoadTests))]
public void Test(GeneralStateTest test)
{
[TestCaseSource(nameof(LoadTests))]
public void Test(GeneralStateTest test)
{
Assert.True(RunTest(test).Pass);
}
Assert.That(RunTest(test).Pass, Is.True);
}

public static IEnumerable<GeneralStateTest> LoadTests()
{
var loader = new TestsSourceLoader(new LoadLegacyGeneralStateTestsStrategy(), "stAttackTest");
return (IEnumerable<GeneralStateTest>)loader.LoadTests();
}
public static IEnumerable<GeneralStateTest> LoadTests()
{
var loader = new TestsSourceLoader(new LoadLegacyGeneralStateTestsStrategy(), "stAttackTest");
return (IEnumerable<GeneralStateTest>)loader.LoadTests();
}
}
Loading

0 comments on commit e1a7e38

Please sign in to comment.