Skip to content

Commit 61cfff3

Browse files
authored
fix: print genesisStateRoot on startup (#1136)
1 parent 478940e commit 61cfff3

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

params/config.go

+7-2
Original file line numberDiff line numberDiff line change
@@ -739,8 +739,13 @@ func (s ScrollConfig) String() string {
739739
maxTxPayloadBytesPerBlock = fmt.Sprintf("%v", *s.MaxTxPayloadBytesPerBlock)
740740
}
741741

742-
return fmt.Sprintf("{useZktrie: %v, maxTxPerBlock: %v, MaxTxPayloadBytesPerBlock: %v, feeVaultAddress: %v, l1Config: %v}",
743-
s.UseZktrie, maxTxPerBlock, maxTxPayloadBytesPerBlock, s.FeeVaultAddress, s.L1Config.String())
742+
genesisStateRoot := "<nil>"
743+
if s.GenesisStateRoot != nil {
744+
genesisStateRoot = fmt.Sprintf("%v", *s.GenesisStateRoot)
745+
}
746+
747+
return fmt.Sprintf("{useZktrie: %v, maxTxPerBlock: %v, MaxTxPayloadBytesPerBlock: %v, feeVaultAddress: %v, l1Config: %v, genesisStateRoot: %v}",
748+
s.UseZktrie, maxTxPerBlock, maxTxPayloadBytesPerBlock, s.FeeVaultAddress, s.L1Config.String(), genesisStateRoot)
744749
}
745750

746751
// IsValidTxCount returns whether the given block's transaction count is below the limit.

0 commit comments

Comments
 (0)