diff --git a/eth/catalyst/api.go b/eth/catalyst/api.go index fa9752734e..8bf9b7cf5f 100644 --- a/eth/catalyst/api.go +++ b/eth/catalyst/api.go @@ -46,6 +46,11 @@ import ( // Register adds the engine API to the full node. func Register(stack *node.Node, backend *eth.Ethereum) error { log.Warn("Engine API enabled", "protocol", "eth") + defer func() { + if r := recover(); r != nil { + err = fmt.Errorf("panic %v when register consensus api", r) + } + }() stack.RegisterAPIs([]rpc.API{ { Namespace: "engine",