Skip to content

Commit 3404f00

Browse files
committed
curio migrate: Fix on-conflict in legacy deals
1 parent e7c0b43 commit 3404f00

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/migrate-curio/migrate.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ func migrateLegacyDeals(ctx context.Context, full v1api.FullNode, activeSectors
458458
piece_size, verified, start_epoch, end_epoch,
459459
publish_cid, chain_deal_id, fast_retrieval, created_at, sector_num)
460460
VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15)
461-
ON CONFLICT (signed_proposal_cid) DO NOTHING`,
461+
ON CONFLICT (sp_id, piece_cid, signed_proposal_cid) DO NOTHING`,
462462
deal.ProposalCid, mid, deal.Client.String(), sigByte, propJson, prop.PieceCID.String(),
463463
prop.PieceSize, prop.VerifiedDeal, prop.StartEpoch, prop.EndEpoch, deal.PublishCid.String(),
464464
deal.DealID, deal.FastRetrieval, deal.CreationTime.Time(), deal.SectorNumber)

0 commit comments

Comments
 (0)