-
-
Notifications
You must be signed in to change notification settings - Fork 931
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
Resolving TypeError, during version unpacking #2098
Resolving TypeError, during version unpacking #2098
Conversation
…ion to some versions of message brokers.
for more information, see https://pre-commit.ci
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.
Thank you for the PR.
Please add tests and fix the lint error.
- Improved my code
…om/couzhei/kombu into bugfix/type-error-version-checking
I really don't get the CI error. I even created a virtual environment from a 3.9 version, but it was okay there. I also have this test, almost always failed: ===================================================== short test summary info =====================================================
FAILED t/unit/transport/test_redis.py::test_Redis::test_publish__consume - OSError: [Errno 9] Bad file descriptor
Results (37.34s):
1181 passed
1 failed
- t/unit/transport/test_redis.py:1373 test_Redis.test_publish__consume
315 skipped
Restoring 2 unacknowledged message(s) Which I'm not sure why it happens when I run tests locally. |
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.
re run the job to see
we just need to fix the lint error |
Thank you, my bad. I have never used pydocstyle, but I have just checked it out, and will be aware of it in the future. |
I think I don't have the right to re-run a job. |
…n `_unpack_version` method - `"` are sent back to `'` (apparently my company's formatter `black` is not compatible with `pydocstyle`, and mine integration with VSCode has messed with kombu's repository)
This reverts commit f3ccc31.
/python3.9/site-packages/kombu/transport/redis.py GlobalKeyPrefixMixin | <class 'kombu.transport.redis.GlobalKeyPrefixMixin'> I tried from supervisor and it seems like it cannot pick the redis version. |
This will make sure that the version unpacking doesn't stop connection to some versions of message brokers. For message brokers with normal-style version, say 3.13.6,
will result in
['3', '13', '6']
list. But for newer releases of rabbitmq, say when you pull docker image using a specified version, in my case4.0-rc
as discussed in this issue related to #2088 it becomes this:which causes that
TypeError
.