Skip to content

Conversation

@jablan
Copy link
Collaborator

@jablan jablan commented Feb 10, 2026

Due to temporarily broken urllib3 (v2.6.0) dependencies, we pinned the version in our Python library. As the urllib maintainers rolled back the change, we don't need to keep the pin anymore, so I relaxed the constraint.

@jablan jablan requested a review from Copilot February 10, 2026 12:45
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Relaxes the previously strict urllib3 upper pin in the generated Python client templates while still excluding the problematic urllib3==2.6.0.

Changes:

  • Updates setup.mustache templates to accept urllib3<3 while excluding 2.6.0.
  • Updates requirements.mustache templates to accept urllib3<3 while excluding 2.6.0.
  • Updates README dependency examples to match the relaxed constraint.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
openapi-generator/templates/python/setup.mustache Relax urllib3 constraint in generated setup.py requirements.
openapi-generator/templates/python/requirements.mustache Relax urllib3 constraint in generated requirements.txt.
openapi-generator/templates/python/python-experimental/setup.mustache Mirrors relaxed urllib3 constraint for experimental generator.
openapi-generator/templates/python/python-experimental/requirements.mustache Mirrors relaxed urllib3 constraint for experimental requirements.
openapi-generator/templates/python/python-experimental/README_onlypackage.mustache Updates documented dependency range for urllib3.
openapi-generator/templates/python/README_onlypackage.mustache Updates documented dependency range for urllib3.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

# http://pypi.python.org/pypi/setuptools

REQUIRES = ["urllib3>=1.15,<2.6", "six >= 1.10", "certifi", "python-dateutil"]
REQUIRES = ["urllib3>=1.15,<3,!=2.6.0", "six >= 1.10", "certifi", "python-dateutil"]
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The urllib3 lower bound here (>=1.15) is inconsistent with the requirements.mustache lower bound (>=1.15.1) and the README examples (>=1.15). This makes it harder to reason about the actual supported range and can lead to mismatched installs depending on which artifact a consumer uses. Recommend standardizing the urllib3 specifier (same lower bound + exclusions) across setup/requirements/README templates.

Suggested change
REQUIRES = ["urllib3>=1.15,<3,!=2.6.0", "six >= 1.10", "certifi", "python-dateutil"]
REQUIRES = ["urllib3>=1.15.1,<3,!=2.6.0", "six >= 1.10", "certifi", "python-dateutil"]

Copilot uses AI. Check for mistakes.
python_dateutil >= 2.5.3
setuptools >= 21.0.0
urllib3 >= 1.15.1, < 2.6
urllib3 >= 1.15.1, < 3, != 2.6.0
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The version specifier formatting differs between templates (e.g., urllib3>=1.15,<3,!=2.6.0 in setup.mustache vs urllib3 >= 1.15.1, < 3, != 2.6.0 here). While both are valid, keeping consistent spacing/formatting across generated artifacts improves readability and reduces churn in downstream diffs. Consider adopting one canonical style (with or without spaces) across all templates.

Suggested change
urllib3 >= 1.15.1, < 3, != 2.6.0
urllib3>=1.15.1,<3,!=2.6.0

Copilot uses AI. Check for mistakes.
@jablan jablan requested a review from BlumMichael February 10, 2026 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant