test(evm): cover delegate call storage regression#13010
Merged
ZenGround0 merged 4 commits intomasterfrom Apr 22, 2025
Merged
Conversation
Stebalien
approved these changes
Apr 4, 2025
Member
|
I applied this diff to the test: diff --git a/itests/eth_proxy_mint_test.go b/itests/eth_proxy_mint_test.go
index 9ca2f6a6b..1fbe4b49d 100644
--- a/itests/eth_proxy_mint_test.go
+++ b/itests/eth_proxy_mint_test.go
@@ -11,9 +11,13 @@ import (
"github.com/stretchr/testify/require"
+ "github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/go-state-types/big"
+ "github.com/filecoin-project/go-state-types/network"
"github.com/filecoin-project/lotus/build/buildconstants"
+ "github.com/filecoin-project/lotus/chain/consensus/filcns"
+ "github.com/filecoin-project/lotus/chain/stmgr"
"github.com/filecoin-project/lotus/chain/types"
"github.com/filecoin-project/lotus/chain/types/ethtypes"
"github.com/filecoin-project/lotus/itests/kit"
@@ -29,16 +33,47 @@ import (
// We're using these to reproduce https://github.com/recallnet/contracts/issues/98
func TestMintContract(t *testing.T) {
blockTime := 100 * time.Millisecond
- client, _, ens := kit.EnsembleMinimal(
- t,
+
+ kit.QuietMiningLogs()
+
+ var (
+ nv25Epoch abi.ChainEpoch = 100
+ nv26Epoch abi.ChainEpoch = nv25Epoch + 100
+ teepFixEpoch abi.ChainEpoch = nv26Epoch + 100
+ )
+ const networkName = "testing-fake-proofs"
+ buildconstants.UpgradeTockFixHeight = teepFixEpoch // needed to be set for migration to run
+
+ client, _, ens := kit.EnsembleMinimal(t,
kit.MockProofs(),
- kit.ThroughRPC())
+ kit.ThroughRPC(),
+ kit.NetworkName(networkName),
+ kit.UpgradeSchedule(stmgr.Upgrade{
+ Network: network.Version24,
+ Height: -1,
+ }, stmgr.Upgrade{
+ Height: nv25Epoch,
+ Network: network.Version25,
+ Migration: filcns.UpgradeActorsV16,
+ Expensive: true,
+ }, stmgr.Upgrade{
+ Height: nv26Epoch,
+ Network: network.Version26,
+ Migration: nil,
+ }, stmgr.Upgrade{
+ Height: teepFixEpoch,
+ Network: network.Version26,
+ Migration: filcns.UpgradeActorsV16Fix,
+ },
+ ))
ens.InterconnectAll().BeginMining(blockTime)
ctx, cancel := context.WithTimeout(context.Background(), time.Minute)
defer cancel()
+ client.WaitTillChain(ctx, kit.HeightAtLeast(teepFixEpoch+5))
+
// Read implementation contract bytecode
impContractHex, err := os.ReadFile("./contracts/MintImpl.hex")
require.NoError(t, err)I then changes the
The failures were the same, below: Which I think means we can both reproduce the problem and confirm that the calibnet fix should address it and that 16.0.1 on mainnet will be fine. 👌 |
rvagg
approved these changes
Apr 5, 2025
6ddedd5 to
6d500be
Compare
Member
|
unrelated flaky itest noted here #13005 |
Member
|
@ZenGround0 : are you good to merge? |
6d500be to
927746b
Compare
Contributor
Author
|
Yes, I just kept forgetting to check / rerun CI after hitting flaky tests. Let's see if everything works this time 🤞 |
8 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related Issues
Proposed Changes
Test for the delegatecall storage regression we caught in nv25 release
Additional Info
This is closely based on builtin actors test: https://github.com/filecoin-project/builtin-actors/pull/1667/files#diff-05c40c02b11471dd4bb78bdd48798ff3c9f8d617e0647dc899d02eaa0834b1f6R717
Checklist
Before you mark the PR ready for review, please make sure that: