Skip to content
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

Fix CI builds by limiting requests version #389

Merged
merged 2 commits into from
Sep 21, 2021
Merged

Fix CI builds by limiting requests version #389

merged 2 commits into from
Sep 21, 2021

Conversation

bxsx
Copy link
Contributor

@bxsx bxsx commented Sep 18, 2021

Description of the change

The latest version of 'requests` (v2.26.0) breaks our Python 3.4 builds. This is because it fails the compatibility check:
https://github.com/psf/requests/blob/a1a6a549a0143d9b32717dbe3d75cd543ae5a4f6/requests/__init__.py#L98-L104

This makes sense when you look here:
https://github.com/psf/requests/blob/a1a6a549a0143d9b32717dbe3d75cd543ae5a4f6/setup.py#L81

Our CI builds seem to always install the latest version regardless of requirements. This is due to a bug in setuptools, which does not respect the maximum version required for installing packages.

The error doesn't occur for Python 3.3 builds as they have a custom setup where pip is responsible for installing requests and it handles the requirements properly.
Python 3.5 passes the compatibility check however, this version is also unsupported and could potentially fail in the future.

This PR explicitly limits the maximum required requests version for each Python version.

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Related issues

Fix [ch91321]

Checklists

Development

  • Lint rules pass locally
  • The code changed/added as part of this pull request has been covered with tests
  • All tests related to the changed code pass in development

Code review

  • This pull request has a descriptive title and information useful to a reviewer. There may be a screenshot or screencast attached
  • "Ready for review" label attached to the PR and reviewers mentioned in a comment
  • Changes have been reviewed by at least one other engineer
  • Issue from task tracker has a link to this pull request

The currently used version of `setuptools` has a bug,
so the version requirements are not properly respected.
In the current version, `requests>= 0.12.1` always installs
the latest version of the package.
@shortcut-integration
Copy link

This pull request has been linked to Shortcut Story #91321: CI builds fail due to wrong requests version.

@bxsx bxsx merged commit faeacd6 into master Sep 21, 2021
@bxsx bxsx deleted the bxsx/fix-setup branch September 21, 2021 10:32
@bxsx bxsx added this to the v0.16.2 milestone Jan 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants