-
Notifications
You must be signed in to change notification settings - Fork 477
feat(job): add moveToCompleted method [python] #3251
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
Conversation
5bf5d2b
to
c145d61
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a new moveToCompleted method on the Job instance to support manual processing.
- Adds moveToCompleted tests for both JavaScript and Python workers.
- Refactors related functions in the Scripts and Worker modules to simplify moveToCompleted/Failed processing.
- Updates the Job class to expose the new moveToCompleted behavior.
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
tests/test_worker.ts | Adds assertions on attemptsMade and finishedOn for JS tests. |
python/tests/worker_test.py | Introduces a test for manual processing and verifies job properties. |
python/bullmq/worker.py | Updates moveToCompleted invocation; removes unused opts parameter. |
python/bullmq/scripts.py | Refactors moveToCompleted and moveToFailed methods and their args. |
python/bullmq/job.py | Implements moveToCompleted to update job status and properties. |
9bdf684
to
ed79d61
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Why
How
Additional Notes (Optional)
Any extra info here.