Skip to content

Commit

Permalink
check-mode: write list of slots before exiting
Browse files Browse the repository at this point in the history
  • Loading branch information
gagliardetto committed Sep 14, 2023
1 parent 29a4671 commit 6541c67
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions cmd/radiance/car/createcar/cmd-create-car.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,12 +220,6 @@ func run(c *cobra.Command, args []string) {
)
}

if *flagCheckOnly {
klog.Infof("Check only; exiting")
time.Sleep(1 * time.Second)
os.Exit(0)
}

// write slots to a file {epoch}.slots.txt
slotsFilepath := filepath.Join(filepath.Dir(finalCARFilepath), fmt.Sprintf("%d.slots.txt", epoch))
klog.Infof("Saving slot list to file: %s", slotsFilepath)
Expand All @@ -241,6 +235,12 @@ func run(c *cobra.Command, args []string) {
}
}

if *flagCheckOnly {
klog.Infof("Check only; exiting")
time.Sleep(1 * time.Second)
os.Exit(0)
}

multi, err := NewMultistage(
finalCARFilepath,
numWorkers,
Expand Down

0 comments on commit 6541c67

Please sign in to comment.