Skip to content

Commit

Permalink
wip: add debug print
Browse files Browse the repository at this point in the history
  • Loading branch information
boodyvo committed Oct 25, 2024
1 parent 2d95f1f commit c69c04d
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions server/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -956,6 +956,19 @@ func startTelemetry(cfg config.Config) (*telemetry.Metrics, error) {

// GenDocProvider returns a function which returns the genesis doc from the genesis file.
func GenDocProvider(cfg *cmtcfg.Config) func() (*cmttypes.GenesisDoc, error) {
fmt.Println("cfg.GenesisFile(): ", cfg.GenesisFile())
file, err := os.Open(filepath.Clean(cfg.GenesisFile()))
if err != nil {
return nil
}

jsonBlob, err := io.ReadAll(file)
if err != nil {
return nil
}

fmt.Println("GenDocProvider jsonBlob: ", string(jsonBlob))

return func() (*cmttypes.GenesisDoc, error) {
appGenesis, err := genutiltypes.AppGenesisFromFile(cfg.GenesisFile())
if err != nil {
Expand Down

0 comments on commit c69c04d

Please sign in to comment.