diff --git a/beacon_chain/beacon_chain_db.nim b/beacon_chain/beacon_chain_db.nim index 64d2fb3a9..747777bf6 100644 --- a/beacon_chain/beacon_chain_db.nim +++ b/beacon_chain/beacon_chain_db.nim @@ -508,7 +508,7 @@ proc new*(T: type BeaconChainDB, # V1 - expected-to-be small rows get without rowid optimizations keyValues = kvStore db.openKvStore("key_values", true).expectDb() - blocks = [ + blocks = if cfg.FULU_FORK_EPOCH != FAR_FUTURE_EPOCH: [ kvStore db.openKvStore("blocks").expectDb(), kvStore db.openKvStore("altair_blocks").expectDb(), kvStore db.openKvStore("bellatrix_blocks").expectDb(), @@ -517,16 +517,34 @@ proc new*(T: type BeaconChainDB, kvStore db.openKvStore("electra_blocks").expectDb(), kvStore db.openKvStore("fulu_blocks").expectDb()] + else: [ + kvStore db.openKvStore("blocks").expectDb(), + kvStore db.openKvStore("altair_blocks").expectDb(), + kvStore db.openKvStore("bellatrix_blocks").expectDb(), + kvStore db.openKvStore("capella_blocks").expectDb(), + kvStore db.openKvStore("deneb_blocks").expectDb(), + kvStore db.openKvStore("electra_blocks").expectDb(), + kvStore db.openKvStore("").expectDb()] + stateRoots = kvStore db.openKvStore("state_roots", true).expectDb() - statesNoVal = [ - kvStore db.openKvStore("state_no_validators2").expectDb(), - kvStore db.openKvStore("altair_state_no_validators").expectDb(), - kvStore db.openKvStore("bellatrix_state_no_validators").expectDb(), - kvStore db.openKvStore("capella_state_no_validator_pubkeys").expectDb(), - kvStore db.openKvStore("deneb_state_no_validator_pubkeys").expectDb(), - kvStore db.openKvStore("electra_state_no_validator_pubkeys").expectDb(), - kvStore db.openKvStore("fulu_state_no_validator_pubkeys").expectDb()] + statesNoVal = if cfg.FULU_FORK_EPOCH != FAR_FUTURE_EPOCH: [ + kvStore db.openKvStore("state_no_validators").expectDb(), + kvStore db.openKvStore("altair_state_no_validators").expectDb(), + kvStore db.openKvStore("bellatrix_state_no_validators").expectDb(), + kvStore db.openKvStore("capella_state_no_validator_pubkeys").expectDb(), + kvStore db.openKvStore("deneb_state_no_validator_pubkeys").expectDb(), + kvStore db.openKvStore("electra_state_no_validator_pubkeys").expectDb(), + kvStore db.openKvStore("fulu_state_no_validator_pubkeys").expectDb()] + + else: [ + kvStore db.openKvStore("state_no_validators").expectDb(), + kvStore db.openKvStore("altair_state_no_validators").expectDb(), + kvStore db.openKvStore("bellatrix_state_no_validators").expectDb(), + kvStore db.openKvStore("capella_state_no_validator_pubkeys").expectDb(), + kvStore db.openKvStore("deneb_state_no_validator_pubkeys").expectDb(), + kvStore db.openKvStore("electra_state_no_validator_pubkeys").expectDb(), + kvStore db.openKvStore("").expectDb()] stateDiffs = kvStore db.openKvStore("state_diffs").expectDb() summaries = kvStore db.openKvStore("beacon_block_summaries", true).expectDb() diff --git a/beacon_chain/consensus_object_pools/consensus_manager.nim b/beacon_chain/consensus_object_pools/consensus_manager.nim index d54f88caf..d6261b62b 100644 --- a/beacon_chain/consensus_object_pools/consensus_manager.nim +++ b/beacon_chain/consensus_object_pools/consensus_manager.nim @@ -379,6 +379,7 @@ proc runProposalForkchoiceUpdated*( debug "Fork-choice updated for proposal", status static: doAssert high(ConsensusFork) == ConsensusFork.Fulu + debugFuluComment "Will Fulu need fcuV4? Or there shall be a new fcuV introduced in Fulu? We don't know" when consensusFork >= ConsensusFork.Deneb: # https://github.com/ethereum/execution-apis/blob/90a46e9137c89d58e818e62fa33a0347bba50085/src/engine/prague.md # does not define any new forkchoiceUpdated, so reuse V3 from Dencun diff --git a/beacon_chain/gossip_processing/block_processor.nim b/beacon_chain/gossip_processing/block_processor.nim index 6e24dd585..c8a009c7e 100644 --- a/beacon_chain/gossip_processing/block_processor.nim +++ b/beacon_chain/gossip_processing/block_processor.nim @@ -772,6 +772,7 @@ proc storeBlock( deadlineObj = deadlineObj, maxRetriesCount = getRetriesCount()) + debugFuluComment "We don't know yet if there'd be new PayloadAttributes version in Fulu." template callForkChoiceUpdated: auto = case self.consensusManager.dag.cfg.consensusForkAtEpoch( newHead.get.blck.bid.slot.epoch) diff --git a/beacon_chain/spec/keystore.nim b/beacon_chain/spec/keystore.nim index 4f2006615..80dd1c786 100644 --- a/beacon_chain/spec/keystore.nim +++ b/beacon_chain/spec/keystore.nim @@ -727,6 +727,7 @@ template writeValue*(w: var JsonWriter, func parseProvenBlockProperty*(propertyPath: string): Result[ProvenProperty, string] = if propertyPath == ".execution_payload.fee_recipient": + debugFuluComment "We don't know yet if `GeneralizedIndex` will stay same in Fulu yet." ok ProvenProperty( path: propertyPath, capellaIndex: some GeneralizedIndex(401),