Skip to content

fix(http-client-python): upgrade Python installers - #12362

Draft
Libba Lawrence (l0lawrence) wants to merge 7 commits into
microsoft:mainfrom
l0lawrence:l0lawrence-python-emitter-tooling-minimums
Draft

Libba Lawrence (l0lawrence) wants to merge 7 commits into
microsoft:mainfrom
l0lawrence:l0lawrence-python-emitter-tooling-minimums

Conversation

@l0lawrence

@l0lawrence Libba Lawrence (l0lawrence) commented Oct 22, 2026 •

Copy link
Copy Markdown
Member

No description provided.

Copilot AI balanced review requested due to automatic review settings October 22, 2026 17:13
@microsoft-github-policy-service microsoft-github-policy-service Bot added emitter:client:python Issue for the Python client emitter: @typespec/http-client-python eng labels Oct 22, 2026
@l0lawrence Libba Lawrence (l0lawrence) changed the title fix(http-client-python): upgrade Python installers with security minimums fix(http-client-python): upgrade Python installers Oct 22, 2026
@pkg-pr-new

pkg-pr-new Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/@typespec/http-client-python@12362

commit: 77fbc69

@github-actions

github-actions Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

All changed packages have been documented.

  • ✅ @typespec/http-client-python
Show changes

@typespec/http-client-python - fix ✏️

Upgrade pip in existing generator virtual environments as well as newly created ones.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Setup can fail with older host pip versions, and subsequent generator installs can bypass the upgraded uv executable.

2 open issues
What changed in this PR

This PR updates Python installer minimums for the HTTP client emitter’s setup, tests, and CI.

Changes:

  • Adds pip and uv upgrades during virtual-environment setup and test-package installation.
  • Raises test dependency minimums for pip, uv, and certifi.
  • Adds installer upgrades to Python CI jobs and records the change in Chronus.
File Description
packages/​http-client-python/​tests/​requirements/​docs.txt Sets the documentation environment’s pip minimum.
packages/​http-client-python/​tests/​requirements/​base.txt Adds pip, uv, and certifi minimums.
packages/​http-client-python/​tests/​install_packages.py Upgrades tooling before installing generated test packages.
packages/​http-client-python/​eng/​scripts/​setup/​package_manager.py Adds tooling upgrades when preparing generator environments.
.github/​workflows/​ci-python.yml Upgrades installers before Python setup in CI jobs.
.chronus/​changes/​python-tooling-minimums-2026-10-22.md Documents the tooling and dependency updates.

Review effort: Balanced

if package_manager == "uv":
command = host_install + ["--python", venv_context.env_exe, "--upgrade", "--prerelease=disallow"]
else:
command = host_install[:-1] + ["--python", venv_context.env_exe, "install", "--upgrade"]

return MockVenvContext(venv_path)
context = MockVenvContext(venv_path)
upgrade_tooling(context, package_manager)
Copilot AI balanced review requested due to automatic review settings October 22, 2026 17:19
env_builder = venv.EnvBuilder(with_pip=False)
context = env_builder.ensure_directories(venv_path)
else:
env_builder = ExtendedEnvBuilder(with_pip=True, upgrade_deps=True)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

this technically should upgrade deps but I dont know if it guarentees the lowest min version

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🔵 Needs a closer look

Compatibility with older host installers and use of the upgraded environment-local tooling remain unverified.

2 open issues

Review effort: Balanced

@github-actions

github-actions Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Python emitter diff

Baseline gh:b57733aadab4922c464cf056b999bfad3d5cd79f vs this PR.

No changes to generated output.

Rendered diff: inline on the run summary, or the emitter-diff-html artifact.

Informational check (eng/emitter-diff); does not block the PR.

@l0lawrence
Libba Lawrence (l0lawrence) marked this pull request as draft October 22, 2026 17:52
@azure-sdk-automation

azure-sdk-automation Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

You can try these changes here

🛝 Playground 🌐 Website 🛝 VSCode Extension

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

emitter:client:python Issue for the Python client emitter: @typespec/http-client-python eng

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants