-
Notifications
You must be signed in to change notification settings - Fork 60
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
CI: Pin requests' version less than 2.32 #382
CI: Pin requests' version less than 2.32 #382
Conversation
12a9d15
to
dbc8478
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. Thanks @BbolroC!
dbc8478
to
c86b501
Compare
The issue docker/docker-py#3113 seems to be resolved. The pinned version of requests (2.28.1) is no longer compatible with the current docker pip, resulting in errors like: "Error connecting: Error while fetching server API version: Not supported URL scheme http+docker" Initially, we attempted to allow pip to install requests according to its dependency tree. However, the issue persists on Ubuntu 22.04, and it appears to be related to docker/docker-py#3256. The best solution so far is to pin the version of the package to less than 2.32. Fixes: confidential-containers#381 Signed-off-by: Hyounggyu Choi <[email protected]>
c86b501
to
5eaedb9
Compare
- name: Downgrade requests | ||
shell: | | ||
actual_version="$(pip3 show requests | grep Version | cut -d: -f2 | xargs)" | ||
version_ge="$(echo -e "2.29.0\n$actual_version" | sort -V | head -1)" |
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.
The other day I was looking for this exact line and I couldn't find. This is a good way to compare semver numbers in bash. So long lovely code, so long!
fi | ||
name: | ||
- docker | ||
- requests<2.32 |
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.
And I didn't know we could specify '<', '>', ...., in this command. Cool!
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.
@BbolroC great debug and fix! thanks!
The issue docker/docker-py#3113 seems to be resolved. The pinned version of requests (2.28.1) is no longer compatible with the current docker pip, resulting in errors like:
Initially, we attempted to allow pip to install requests according to its dependency tree.
However, the issue persists on Ubuntu 22.04, and it appears to be related to docker/docker-py#3256.
The best solution so far is to pin the version of the package to less than 2.32.
The change is verified at https://github.com/confidential-containers/operator/actions/runs/9204691086?pr=382
Fixes: #381
Signed-off-by: Hyounggyu Choi [email protected]