diff --git a/lib/harmony/harmonydb/sql/20230823.sql b/lib/harmony/harmonydb/sql/20230823.sql index d2d954c7c..750b7ea25 100644 --- a/lib/harmony/harmonydb/sql/20230823.sql +++ b/lib/harmony/harmonydb/sql/20230823.sql @@ -25,7 +25,7 @@ create table wdpost_proofs partition bigint not null, submit_at_epoch bigint not null, submit_by_epoch bigint not null, - proof_message bytea, + proof_params bytea, submit_task_id bigint, message_cid text, diff --git a/provider/lpmessage/sender.go b/provider/lpmessage/sender.go index f6bd0a8a7..5123410c9 100644 --- a/provider/lpmessage/sender.go +++ b/provider/lpmessage/sender.go @@ -157,6 +157,8 @@ func (s *Sender) Send(ctx context.Context, msg *types.Message, mss *api.MessageS // push to mpool _, err = s.api.MpoolPush(ctx, sigMsg) if err != nil { + // TODO: We may get nonce gaps here.. + return cid.Undef, xerrors.Errorf("mpool push: failed to push message: %w", err) } diff --git a/provider/lpwindow/compute_task.go b/provider/lpwindow/compute_task.go index 372de22fc..949c09365 100644 --- a/provider/lpwindow/compute_task.go +++ b/provider/lpwindow/compute_task.go @@ -170,7 +170,7 @@ func (t *WdPostTask) Do(taskID harmonytask.TaskID, stillOwned func() bool) (done partition, submit_at_epoch, submit_by_epoch, - proof_message) + proof_params) VALUES ($1, $2, $3, $4, $5, $6, $7)`, spID, pps, diff --git a/provider/lpwindow/submit_task.go b/provider/lpwindow/submit_task.go index d387a9f06..cfae3e292 100644 --- a/provider/lpwindow/submit_task.go +++ b/provider/lpwindow/submit_task.go @@ -79,7 +79,7 @@ func (w *WdPostSubmitTask) Do(taskID harmonytask.TaskID, stillOwned func() bool) var dbTask uint64 err = w.db.QueryRow( - context.Background(), `SELECT sp_id, proving_period_start, deadline, partition, submit_at_epoch, submit_by_epoch, proof_message, submit_task_id + context.Background(), `SELECT sp_id, proving_period_start, deadline, partition, submit_at_epoch, submit_by_epoch, proof_params, submit_task_id FROM wdpost_proofs WHERE submit_task_id = $1`, taskID, ).Scan(&spID, &pps, &deadline, &partition, &submitAtEpoch, &submitByEpoch, &earlyParamBytes, &dbTask) if err != nil {