Skip to content

fix(pypi): correctly handle custom names in pipstar platforms - #3054

Merged
aignas merged 2 commits into
bazel-contrib:mainfrom
aignas:fix/platform_name
Jul 7, 2025
Merged

fix(pypi): correctly handle custom names in pipstar platforms#3054
aignas merged 2 commits into
bazel-contrib:mainfrom
aignas:fix/platform_name

Conversation

@aignas

Copy link
Copy Markdown
Collaborator

Before it seems that we were relying on particular names in the pipstar
platforms. This ensures that we rely on this less. Whilst at it fix a
few typos and improve the formatting of the code.

Work towards #2949
Work towards #2747

Before it seems that we were relying on particular names in the pipstar
platforms. This ensures that we rely on this less. Whilst at it fix a
few typos and improve the formatting of the code.
Work towards bazel-contrib#2949
Work towards bazel-contrib#2747
@aignas
aignasforce-pushed the fix/platform_name branch from 2f64607 to ead6071CompareJuly 6, 2025 13:21
@aignas

Copy link
Copy Markdown
CollaboratorAuthor

The requirement_files_by_platform is still a little broken as we can see in #3063.

Comment threadpython/private/pypi/extension.bzl Outdated
fail("Unsupported key in the PEP508 environment: {}".format(key))

if not os_name:
fail("'os_name' is required")

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Were os_name and arch_name effectively required before, or is this new? Though, I think this pip.defaults API is still experimental, right?

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

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

This is new. It is experimental, but I've been dragging some of the hidden constants from various parts of the PyPI code into the internally defined pip.default instances. This has been really useful in that sense. I think maybe I want to revert this requirement. It is not going to be compatible with the builder pattern.

Comment threadpython/private/pypi/extension.bzl Outdated
@aignas
aignas enabled auto-merge July 7, 2025 02:08
@aignas
aignas added this pull request to the merge queueJul 7, 2025
Merged via the queue into bazel-contrib:main with commit 3d93274Jul 7, 2025
@aignas
aignas deleted the fix/platform_name branch July 7, 2025 04:28
Sign up for freeto 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.

2 participants

@aignas@rickeylev