Skip to content

Commit

Permalink
curio: Only open db in sectors migrate cmd
Browse files Browse the repository at this point in the history
  • Loading branch information
magik6k committed Apr 26, 2024
1 parent 3fd3d07 commit 6f79c24
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/curio/pipeline.go
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ var sealMigrateLMSectorsCmd = &cli.Command{
},
Action: func(cctx *cli.Context) error {
ctx := lcli.ReqContext(cctx)
dep, err := deps.GetDepsCLI(ctx, cctx)
db, err := deps.MakeDB(cctx)
if err != nil {
return err
}
Expand Down Expand Up @@ -196,7 +196,7 @@ var sealMigrateLMSectorsCmd = &cli.Command{
return xerrors.Errorf("parsing miner actor address: %w", err)
}

err = guidedsetup.MigrateSectors(ctx, addr, mmeta, dep.DB, func(n int) {
err = guidedsetup.MigrateSectors(ctx, addr, mmeta, db, func(n int) {
fmt.Printf("Migrating %d sectors\n", n)
})
if err != nil {
Expand Down

0 comments on commit 6f79c24

Please sign in to comment.