Skip to content

ci(deps): respect version constraints when pinning grace-period-safe … - #920

Open
arjun-rajappa wants to merge 1 commit into
mainfrom
ci/pin-safe-versions-respect-specifiers
Open

arjun-rajappa wants to merge 1 commit into
mainfrom
ci/pin-safe-versions-respect-specifiers

Conversation

@arjun-rajappa

Copy link
Copy Markdown
Contributor

Why

pin_safe_versions.py downgraded recently released packages without looking at the version constraints in the requirements files. It could pin to a version that violates a bound such as fastapi>=0.92.0,<0.129.0. It also silently skipped packages whose names differ only in -, _ or ., and it could try a back-ported older release before the newest one.

…packages

Parse requirement specifiers and environment markers from the requirements
file and only downgrade to versions that satisfy them. Canonicalize package
names (PEP 503) so names like typing_extensions and typing-extensions match,
and select the newest candidate by version rather than upload date.

Signed-off-by: Arjun Rajappa <arjun.rajappa@ibm.com>
@arjun-rajappa arjun-rajappa self-assigned this Nov 4, 2026
@arjun-rajappa
arjun-rajappa requested a review from a team as a code owner November 4, 2026 07:47

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant