本文介绍了警告:apscheduler.scheduler:跳过作业的执行:达到最大运行实例数(1)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在我的代码中,我运行了每五秒运行一次的 cron 作业,从那以后我一直收到相同的警告.
In my code i run a cron job which is run for every five seconds, and I've been getting the same WARNING ever since.
这是我使用的api:
sched.add_cron_job(test_3, second="*/5")
然后我收到警告:
WARNING:apscheduler.scheduler:Execution of job "test_3 (trigger: cron[second='*/5'], next run at: 2013-11-28 15:56:30)" skipped: maximum number of running instances reached (1)
我试过给 2 分钟的时间间隔它不能解决问题.....帮助我解决这个问题..
I tried giving time gap of 2 minutes it doesn't solve the issue.....Help me in overcoming this issue..
推荐答案
我遇到了类似的问题,结果证明这只是您的工作test_3"持续时间太长,超过 5 秒(或您尝试的 2 分钟)).APScheduler 正在尝试重新执行您的作业,但前一个作业仍在运行.
I had a similar problem, and it turned out it was just your job 'test_3' lasting too long, more then 5 secs (or 2 minutes as you tried).APScheduler is trying to re-execute you job, but the previous one is still running.
这篇关于警告:apscheduler.scheduler:跳过作业的执行:达到最大运行实例数(1)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!