pyspider icon indicating copy to clipboard operation
pyspider copied to clipboard

Fix bug: Scheduler paused forever

Open ghost opened this issue 6 years ago • 2 comments

Environment

pyspider version: 0.3.10
oprate system version: ubuntu
launch command:pyspider -c config.json

I found if my project is paused, I can not recover my project while my project only product many on_cronjob tasks every n seconds.

My case:

Run on_start every 5 seconds. After my project paused, my project active_tasks was filled by on_cronjob tasks. My project _paused is "checking" forever.

ghost avatar Feb 25 '19 11:02 ghost

I have pushed PR. Thank you very much.

ghost avatar Feb 25 '19 11:02 ghost

to unpause, the project have to have:

  1. at least UNPAUSE_CHECK_NUM task state respond with in last ACTIVE_TASKS.
  2. at least 1 process ok

selected tasks without respond is NOT considered as success tasks (as your code changes), which shouldn't unpause the project.

binux avatar Mar 09 '19 23:03 binux