From 3c2c0d2ef7dde470822b3b2792dedcc3dac03853 Mon Sep 17 00:00:00 2001 From: Martin Holst Swende Date: Thu, 19 Sep 2024 10:36:27 +0200 Subject: [PATCH] eth/catalyst: use setcanonical instead of sethead in simulated fork --- eth/catalyst/simulated_beacon.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/eth/catalyst/simulated_beacon.go b/eth/catalyst/simulated_beacon.go index cb27810aac..1857d87906 100644 --- a/eth/catalyst/simulated_beacon.go +++ b/eth/catalyst/simulated_beacon.go @@ -306,7 +306,8 @@ func (c *SimulatedBeacon) Fork(parentHash common.Hash) error { if parent == nil { return errors.New("parent not found") } - return c.eth.BlockChain().SetHead(parent.NumberU64()) + _, err := c.eth.BlockChain().SetCanonical(parent) + return err } // AdjustTime creates a new block with an adjusted timestamp.