sectorstorage: Untangle from lotus deps

This commit is contained in:
Łukasz Magiera 2020-03-27 21:08:06 +01:00
parent ed6202d202
commit 089c769373
2 changed files with 4 additions and 3 deletions

View File

@ -2,13 +2,13 @@ package sealing
import (
"context"
"github.com/filecoin-project/lotus/storage/sectorstorage/ffiwrapper"
"io"
"golang.org/x/xerrors"
"github.com/filecoin-project/specs-actors/actors/abi"
"github.com/filecoin-project/lotus/api"
"github.com/filecoin-project/lotus/lib/nullreader"
)
@ -49,7 +49,7 @@ func (m *Sealing) PledgeSector() error {
size := abi.PaddedPieceSize(m.sealer.SectorSize()).Unpadded()
_, rt, err := api.ProofTypeFromSectorSize(m.sealer.SectorSize())
_, rt, err := ffiwrapper.ProofTypeFromSectorSize(m.sealer.SectorSize())
if err != nil {
log.Error(err)
return

View File

@ -2,6 +2,7 @@ package sealing
import (
"context"
"github.com/filecoin-project/lotus/storage/sectorstorage/ffiwrapper"
"io"
"github.com/filecoin-project/go-address"
@ -132,7 +133,7 @@ func (m *Sealing) SealPiece(ctx context.Context, size abi.UnpaddedPieceSize, r i
return xerrors.Errorf("adding piece to sector: %w", err)
}
_, rt, err := api.ProofTypeFromSectorSize(m.sealer.SectorSize())
_, rt, err := ffiwrapper.ProofTypeFromSectorSize(m.sealer.SectorSize())
if err != nil {
return xerrors.Errorf("bad sector size: %w", err)
}