From 514d4431caae8ecf158589c3052f64f6de4c37f6 Mon Sep 17 00:00:00 2001 From: Etan Kissling Date: Fri, 13 Jan 2023 20:11:05 +0100 Subject: [PATCH] Use `bellatrix` in `upgrade_x_to_capella` helpers --- specs/capella/light-client/fork.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/specs/capella/light-client/fork.md b/specs/capella/light-client/fork.md index d5640e01b0..6dcc7578c2 100644 --- a/specs/capella/light-client/fork.md +++ b/specs/capella/light-client/fork.md @@ -22,14 +22,14 @@ This document describes how to upgrade existing light client objects based on th A Capella `LightClientStore` can still process earlier light client data. In order to do so, that pre-Capella data needs to be locally upgraded to Capella before processing. ```python -def upgrade_lc_header_to_capella(pre: altair.LightClientHeader) -> LightClientHeader: +def upgrade_lc_header_to_capella(pre: bellatrix.LightClientHeader) -> LightClientHeader: return LightClientHeader( beacon=pre.beacon, ) ``` ```python -def upgrade_lc_bootstrap_to_capella(pre: altair.LightClientBootstrap) -> LightClientBootstrap: +def upgrade_lc_bootstrap_to_capella(pre: bellatrix.LightClientBootstrap) -> LightClientBootstrap: return LightClientBootstrap( header=upgrade_lc_header_to_capella(pre.header), current_sync_committee=pre.current_sync_committee, @@ -38,7 +38,7 @@ def upgrade_lc_bootstrap_to_capella(pre: altair.LightClientBootstrap) -> LightCl ``` ```python -def upgrade_lc_update_to_capella(pre: altair.LightClientUpdate) -> LightClientUpdate: +def upgrade_lc_update_to_capella(pre: bellatrix.LightClientUpdate) -> LightClientUpdate: return LightClientUpdate( attested_header=upgrade_lc_header_to_capella(pre.attested_header), next_sync_committee=pre.next_sync_committee, @@ -51,7 +51,7 @@ def upgrade_lc_update_to_capella(pre: altair.LightClientUpdate) -> LightClientUp ``` ```python -def upgrade_lc_finality_update_to_capella(pre: altair.LightClientFinalityUpdate) -> LightClientFinalityUpdate: +def upgrade_lc_finality_update_to_capella(pre: bellatrix.LightClientFinalityUpdate) -> LightClientFinalityUpdate: return LightClientFinalityUpdate( attested_header=upgrade_lc_header_to_capella(pre.attested_header), finalized_header=upgrade_lc_header_to_capella(pre.finalized_header), @@ -62,7 +62,7 @@ def upgrade_lc_finality_update_to_capella(pre: altair.LightClientFinalityUpdate) ``` ```python -def upgrade_lc_optimistic_update_to_capella(pre: altair.LightClientOptimisticUpdate) -> LightClientOptimisticUpdate: +def upgrade_lc_optimistic_update_to_capella(pre: bellatrix.LightClientOptimisticUpdate) -> LightClientOptimisticUpdate: return LightClientOptimisticUpdate( attested_header=upgrade_lc_header_to_capella(pre.attested_header), sync_aggregate=pre.sync_aggregate, @@ -75,7 +75,7 @@ def upgrade_lc_optimistic_update_to_capella(pre: altair.LightClientOptimisticUpd Existing `LightClientStore` objects based on Altair MUST be upgraded to Capella before Capella based light client data can be processed. The `LightClientStore` upgrade MAY be performed before `CAPELLA_FORK_EPOCH`. ```python -def upgrade_lc_store_to_capella(pre: altair.LightClientStore) -> LightClientStore: +def upgrade_lc_store_to_capella(pre: bellatrix.LightClientStore) -> LightClientStore: if pre.best_valid_update is None: best_valid_update = None else: