From ab53055c719d0d0c910a3a924823a6f2ea69ad7a Mon Sep 17 00:00:00 2001 From: Sam Calder-Mason Date: Thu, 7 Sep 2023 10:47:36 +1000 Subject: [PATCH] feat: Subscribe to finalized_checkpoint events --- pkg/beacon/nodes.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkg/beacon/nodes.go b/pkg/beacon/nodes.go index 3c62e37..496c1fd 100644 --- a/pkg/beacon/nodes.go +++ b/pkg/beacon/nodes.go @@ -36,8 +36,11 @@ func NewNodesFromConfig(log logrus.FieldLogger, configs []node.Config, namespace snode := sbeacon.NewNode(log.WithField("upstream", config.Name), sconfig, namespace, opts) - // TODO(sam.calder-mason): Can we re-enable this if we're expecting to use a full beacon node for v1? - snode.Options().BeaconSubscription.Enabled = false + snode.Options().BeaconSubscription.Enabled = true + + opts.BeaconSubscription.Topics = sbeacon.EventTopics{ + "finalized_checkpoint", + } nodes[i] = &Node{ Config: config,