Break out of retrieval if provider cancels

This commit is contained in:
Geoff Stuart 2022-06-23 16:59:44 -04:00
parent a80da7f1f9
commit c10c89883c

View File

@ -194,6 +194,8 @@ func retrieve(ctx context.Context, cctx *cli.Context, fapi lapi.FullNode, sel *l
break readEvents break readEvents
case retrievalmarket.DealStatusRejected: case retrievalmarket.DealStatusRejected:
return nil, xerrors.Errorf("Retrieval Proposal Rejected: %s", evt.Message) return nil, xerrors.Errorf("Retrieval Proposal Rejected: %s", evt.Message)
case retrievalmarket.DealStatusCancelled:
return nil, xerrors.Errorf("Retrieval Proposal Cancelled: %s", evt.Message)
case case
retrievalmarket.DealStatusDealNotFound, retrievalmarket.DealStatusDealNotFound,
retrievalmarket.DealStatusErrored: retrievalmarket.DealStatusErrored: