@@ -146,7 +146,7 @@ func (t *TaskClientPoll) Do(taskID harmonytask.TaskID, stillOwned func() bool) (
146
146
}
147
147
if err != nil && errors .Is (err , pgx .ErrNoRows ) {
148
148
log .Infow ("client request not found" , "taskID" , taskID )
149
- return false , nil
149
+ return true , nil
150
150
}
151
151
152
152
pollCtx , ownedCancel := context .WithCancel (ctx )
@@ -185,7 +185,7 @@ func (t *TaskClientPoll) Do(taskID harmonytask.TaskID, stillOwned func() bool) (
185
185
186
186
// check if the task is still owned
187
187
if ! stillOwned () {
188
- return false , nil
188
+ return false , xerrors . Errorf ( "yield" )
189
189
}
190
190
}
191
191
@@ -235,7 +235,6 @@ func NewTaskClientPoll(db *harmonydb.DB, api ClientServiceAPI) *TaskClientPoll {
235
235
236
236
// pollForProof polls for the proof status
237
237
func pollForProof (ctx context.Context , db * harmonydb.DB , taskID harmonytask.TaskID , clientRequest * ClientRequest ) (bool , []byte , error ) {
238
- log .Infow ("pollForProof" , "taskID" , taskID , "requestCID" , clientRequest .RequestCID )
239
238
// Parse the request CID
240
239
requestCid , err := cid .Parse (* clientRequest .RequestCID )
241
240
if err != nil {
@@ -245,7 +244,6 @@ func pollForProof(ctx context.Context, db *harmonydb.DB, taskID harmonytask.Task
245
244
// Get proof status by CID
246
245
proofResp , err := proofsvc .GetProofStatus (ctx , requestCid )
247
246
if err != nil || proofResp .Proof == nil {
248
- log .Infow ("proof not ready" , "taskID" , taskID , "spID" , clientRequest .SpID , "sectorNumber" , clientRequest .SectorNumber )
249
247
// Not ready yet, continue polling
250
248
return false , nil , nil
251
249
}
0 commit comments