aiojobs icon indicating copy to clipboard operation
aiojobs copied to clipboard

Per-job timeout?

Open Arseniy-Popov opened this issue 10 months ago • 1 comments

Would you consider adding a per-job timeout? How long a job is allowed to remain in the active state. This library seems like the place to put it.

Arseniy-Popov avatar Apr 05 '24 17:04 Arseniy-Popov

I don't think there's any timeout here, is there? To create a timeout for a particular job, just wrap the task in a timeout.

At the very simplest, I think you can just pass asyncio.wait_for(my_task(), timeout), instead of my_task() directly.

Dreamsorcerer avatar Apr 05 '24 17:04 Dreamsorcerer