diff --git a/eth/ethconfig/config.go b/eth/ethconfig/config.go index fef7f29f4e..c9179e9462 100644 --- a/eth/ethconfig/config.go +++ b/eth/ethconfig/config.go @@ -169,14 +169,18 @@ type Config struct { // Clique is allowed for now to live standalone, but ethash is forbidden and can // only exist on already merged networks. func CreateConsensusEngine(config *params.ChainConfig, db ethdb.Database) (consensus.Engine, error) { + // Wrap previously supported consensus engines into their post-merge counterpart + if config.Clique != nil { + // Enforce? + config.TerminalTotalDifficultyPassed = true + return beacon.New(clique.New(config.Clique, db)), nil + } + // Geth v1.14.0 dropped support for non-merged networks in any consensus // mode. If such a network is requested, reject startup. if !config.TerminalTotalDifficultyPassed { return nil, errors.New("only PoS networks are supported, please transition old ones with Geth v1.13.x") } - // Wrap previously supported consensus engines into their post-merge counterpart - if config.Clique != nil { - return beacon.New(clique.New(config.Clique, db)), nil - } + return beacon.New(ethash.NewFaker()), nil }