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

[Holesky][Cancun] Remove cancun timestamp temporarily #6052

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions src/Nethermind/Chains/holesky.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,6 @@
"eip3855TransitionTimestamp": "0x6505e360",
"eip3860TransitionTimestamp": "0x6505e360",
"eip4895TransitionTimestamp": "0x6505e360",
"eip4844TransitionTimestamp": "0x77359400",
"eip4788TransitionTimestamp": "0x77359400",
"eip4788ContractAddress": "0x000000000000000000000000000000000000000b",
"eip1153TransitionTimestamp": "0x77359400",
"eip5656TransitionTimestamp": "0x77359400",
"eip6780TransitionTimestamp": "0x77359400",
"terminalTotalDifficulty": "0x0",
"gasLimitBoundDivisor": "0x400",
"maxCodeSize": "0x6000",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,8 @@ public void Holesky_loads_properly()
new ForkActivation(0, HoleskySpecProvider.GenesisTimestamp),
new ForkActivation(1, HoleskySpecProvider.ShanghaiTimestamp),
new ForkActivation(3, HoleskySpecProvider.ShanghaiTimestamp + 24),
new ForkActivation(4, HoleskySpecProvider.CancunTimestamp),
new ForkActivation(5, HoleskySpecProvider.CancunTimestamp + 12),
//new ForkActivation(4, HoleskySpecProvider.CancunTimestamp),
//new ForkActivation(5, HoleskySpecProvider.CancunTimestamp + 12),
};

CompareSpecProviders(hardCodedSpec, provider, forkActivationsToTest);
Expand All @@ -166,9 +166,8 @@ public void Holesky_loads_properly()
Assert.That(provider.ChainId, Is.EqualTo(BlockchainIds.Holesky));
Assert.That(provider.NetworkId, Is.EqualTo(BlockchainIds.Holesky));

// Still commented since Cancun timestamp is set to be very far but not a 256 slot multiple
//GetTransitionTimestamps(chainSpec.Parameters).Should().AllSatisfy(
// t => ValidateSlotByTimestamp(t, HoleskySpecProvider.GenesisTimestamp).Should().BeTrue());
GetTransitionTimestamps(chainSpec.Parameters).Should().AllSatisfy(
t => ValidateSlotByTimestamp(t, HoleskySpecProvider.GenesisTimestamp).Should().BeTrue());
}

[Test]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ public void Can_load_holesky()
chainSpec.LondonBlockNumber.Should().Be(0);
chainSpec.ShanghaiTimestamp.Should().Be(HoleskySpecProvider.ShanghaiTimestamp);
chainSpec.ShanghaiTimestamp.Should().Be(HoleskySpecProvider.Instance.TimestampFork);
chainSpec.CancunTimestamp.Should().Be(HoleskySpecProvider.CancunTimestamp);
// chainSpec.CancunTimestamp.Should().Be(HoleskySpecProvider.CancunTimestamp);
}

[Test]
Expand Down
8 changes: 4 additions & 4 deletions src/Nethermind/Nethermind.Specs/HoleskySpecProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public class HoleskySpecProvider : ISpecProvider
{
public const ulong GenesisTimestamp = 0x65046360;
public const ulong ShanghaiTimestamp = 0x6505e360;
public const ulong CancunTimestamp = 0x77359400;
// public const ulong CancunTimestamp = 0x77359400;

private HoleskySpecProvider() { }

Expand All @@ -21,8 +21,8 @@ public IReleaseSpec GetSpec(ForkActivation forkActivation)
return forkActivation.Timestamp switch
{
null or < ShanghaiTimestamp => GenesisSpec,
< CancunTimestamp => Shanghai.Instance,
_ => Cancun.Instance
// < CancunTimestamp => Shanghai.Instance,
_ => Shanghai.Instance
};
}

Expand All @@ -44,7 +44,7 @@ public void UpdateMergeTransitionInfo(long? blockNumber, UInt256? terminalTotalD
public ForkActivation[] TransitionActivations { get; } =
{
(1, ShanghaiTimestamp),
(2, CancunTimestamp)
// (2, CancunTimestamp)
};

public static readonly HoleskySpecProvider Instance = new();
Expand Down