-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Fixes #8224 Fixes worker command optimizations flag #8312
Fixes #8224 Fixes worker command optimizations flag #8312
Conversation
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.
did you check the celery 5.0.0 release notes and migration guide?
@auvipy I did, this change is not referenced. There is reference to the CLI changes, but I don't think this change is covered by it: https://docs.celeryq.dev/en/v5.0.0/whatsnew-5.0.html#step-1-adjust-your-command-line-invocation |
Celery 5.0 introduces a new CLI implementation which isn’t completely backwards compatible. The global options can no longer be positioned after the sub-command. Instead, they must be positioned as an option for the celery command like so: |
@Nusnus it would be great if you could take a feedback from Omer |
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #8312 +/- ##
=======================================
Coverage 87.16% 87.16%
=======================================
Files 148 148
Lines 18469 18469
Branches 3148 3148
=======================================
Hits 16098 16098
Misses 2092 2092
Partials 279 279
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
He's OOO so to speak for some time and available only for critical/urgent issues so I prefer to not reach him with that at the moment and help myself instead. So I've reviewed the changes myself, and it makes sense to me. Thank you @stuart-bradley! |
@@ -166,8 +166,8 @@ def detach(path, argv, logfile=None, pidfile=None, uid=None, | |||
type=LOG_LEVEL, | |||
help_group="Worker Options", | |||
help="Logging level.") | |||
@click.option('optimization', | |||
'-O', | |||
@click.option('-O', |
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.
-O before or after? just for double check
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.
Before :)
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.
See code above/below, the pattern is consistent being first -O
, then --optimization
Description
This PR fixes #8224 wherein the
optimizations
flag of the worker command lost its double-
, resulting in unintended breaking behaviour in 5.*.