diff --git a/cmd/util/cmd/verify_execution_result/cmd.go b/cmd/util/cmd/verify_execution_result/cmd.go index 9263773aa5b..cb76a5e51d7 100644 --- a/cmd/util/cmd/verify_execution_result/cmd.go +++ b/cmd/util/cmd/verify_execution_result/cmd.go @@ -93,9 +93,9 @@ func run(*cobra.Command, []string) { } func parseFromTo(fromTo string) (from, to uint64, err error) { - parts := strings.Split(fromTo, "-") + parts := strings.Split(fromTo, "_") if len(parts) != 2 { - return 0, 0, fmt.Errorf("invalid format: expected 'from-to', got '%s'", fromTo) + return 0, 0, fmt.Errorf("invalid format: expected 'from_to', got '%s'", fromTo) } from, err = strconv.ParseUint(strings.TrimSpace(parts[0]), 10, 64) diff --git a/engine/verification/verifier/verifiers.go b/engine/verification/verifier/verifiers.go index 7ccef14982f..62407852406 100644 --- a/engine/verification/verifier/verifiers.go +++ b/engine/verification/verifier/verifiers.go @@ -18,6 +18,7 @@ import ( "github.com/onflow/flow-go/module" "github.com/onflow/flow-go/module/chunks" "github.com/onflow/flow-go/module/metrics" + "github.com/onflow/flow-go/module/util" "github.com/onflow/flow-go/state/protocol" "github.com/onflow/flow-go/storage" storagepebble "github.com/onflow/flow-go/storage/pebble" @@ -125,6 +126,14 @@ func verifyConcurrently( var lowestErrHeight uint64 = ^uint64(0) // Initialize to max value of uint64 var mu sync.Mutex // To protect access to lowestErr and lowestErrHeight + lg := util.LogProgress( + log.Logger, + util.DefaultLogProgressConfig( + fmt.Sprintf("verifying heights progress for [%v:%v]", from, to), + int(to+1-from), + ), + ) + // Worker function worker := func() { for { @@ -154,6 +163,8 @@ func verifyConcurrently( } else { log.Info().Uint64("height", height).Msg("verified height successfully") } + + lg(1) // log progress } } }