Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some jobs occasionally cannot be executed #1002

Open
3 tasks done
yuqiuwen opened this issue Dec 18, 2024 · 1 comment
Open
3 tasks done

Some jobs occasionally cannot be executed #1002

yuqiuwen opened this issue Dec 18, 2024 · 1 comment
Labels

Comments

@yuqiuwen
Copy link

Things to check first

  • I have checked that my issue does not already have a solution in the FAQ

  • I have searched the existing issues and didn't find my bug already reported there

  • I have checked that my bug is still present in the latest release

Version

3.10.4

What happened?

I defined a timed job function, and set the job_id as aps_job:pub_bp:{bp_id}. However, some job_id occasionally cannot be executed, which can be queryed in the apscheduler_jobs table. There are no errors printed.

def publish_bp(bp_id: int):
    ...

scheduler.add_job(
    publish_bp,
    id=job_id,
    name=job_id,
    args=[bp_id],
    run_date=DT.ts2time(ptime),
    misfire_grace_time=600,
)

How can we reproduce the bug?

this is apscheduler config:

SCHEDULER_JOBSTORES = {"default": SQLAlchemyJobStore(url=SQLALCHEMY_BINDS["main"])}
SCHEDULER_EXECUTORS = {
    "default": ThreadPoolExecutor(20),
    "processpool": ProcessPoolExecutor(10),
}
SCHEDULER_JOB_DEFAULTS = {
    "coalesce": False,
    "replace_existing": True,
    "max_instances": 20,
}
@yuqiuwen yuqiuwen added the bug label Dec 18, 2024
@agronholm
Copy link
Owner

If you were me, could you reproduce this issue with the information you've provided?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants