dbader / dbader/schedule

Parallel execution with queue and arguments

Open
#492 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
12.3k
Forks
999
PR merge metrics
No merged PRs in 30d

Description

Is it possible to implement parallel execution with queue and functions with arguments?

Let's say this is my code
have a function foo (a) that I need to call periodically.

`def foo(ar):`
` # do something with ar`
`q = queue.Queue()`
How can I write this next call such that also the argument is passed?
`schedule.every(10).seconds.do(q.put, job).tag("tag")`

I'll handle the queue as reported in the [documentation](https://schedule.readthedocs.io/en/stable/parallel-execution.html)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the parallel execution documentation linked in the issue and the queue.Queue example shown in the body. Clarify how scheduled calls should pass arguments to foo through the queue, then verify the desired behavior with a reproducible example and document or test the completed interface.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.