Skip to content

Commit

Permalink
Intermediate changes
Browse files Browse the repository at this point in the history
commit_hash:7e2cec68f101a9d3cfbac83ec922054c2ddfd0a4
  • Loading branch information
robot-piglet committed Mar 12, 2025
1 parent a1d146f commit 8cba1a8
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 17 deletions.
4 changes: 2 additions & 2 deletions contrib/python/setuptools/py3/.dist-info/METADATA
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Metadata-Version: 2.2
Name: setuptools
Version: 75.8.0
Version: 75.8.1
Summary: Easily download, build, install, upgrade, and uninstall Python packages
Author-email: Python Packaging Authority <[email protected]>
Project-URL: Source, https://github.com/pypa/setuptools
Expand Down Expand Up @@ -98,7 +98,7 @@ Requires-Dist: jaraco.develop>=7.21; sys_platform != "cygwin" and extra == "type
.. |docs-badge| image:: https://img.shields.io/readthedocs/setuptools/latest.svg
:target: https://setuptools.pypa.io

.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2024-informational
.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2025-informational
:target: https://blog.jaraco.com/skeleton

.. |codecov-badge| image:: https://img.shields.io/codecov/c/github/pypa/setuptools/master.svg?logo=codecov&logoColor=white
Expand Down
2 changes: 1 addition & 1 deletion contrib/python/setuptools/py3/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
.. |docs-badge| image:: https://img.shields.io/readthedocs/setuptools/latest.svg
:target: https://setuptools.pypa.io

.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2024-informational
.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2025-informational
:target: https://blog.jaraco.com/skeleton

.. |codecov-badge| image:: https://img.shields.io/codecov/c/github/pypa/setuptools/master.svg?logo=codecov&logoColor=white
Expand Down
8 changes: 7 additions & 1 deletion contrib/python/setuptools/py3/setuptools/_normalization.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,13 @@ def filename_component_broken(value: str) -> str:
def safer_name(value: str) -> str:
"""Like ``safe_name`` but can be used as filename component for wheel"""
# See bdist_wheel.safer_name
return filename_component(safe_name(value))
return (
# Per https://packaging.python.org/en/latest/specifications/name-normalization/#name-normalization
re.sub(r"[-_.]+", "-", safe_name(value))
.lower()
# Per https://packaging.python.org/en/latest/specifications/binary-distribution-format/#escaping-and-unicode
.replace("-", "_")
)


def safer_best_effort_version(value: str) -> str:
Expand Down
14 changes: 2 additions & 12 deletions contrib/python/setuptools/py3/setuptools/command/bdist_wheel.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,13 @@
from wheel.wheelfile import WheelFile

from .. import Command, __version__, _shutil
from .._normalization import safer_name
from ..warnings import SetuptoolsDeprecationWarning
from .egg_info import egg_info as egg_info_cls

from distutils import log


def safe_name(name: str) -> str:
"""Convert an arbitrary string to a standard distribution name
Any runs of non-alphanumeric/. characters are replaced with a single '-'.
"""
return re.sub("[^A-Za-z0-9.]+", "-", name)


def safe_version(version: str) -> str:
"""
Convert an arbitrary string to a standard version string
Expand Down Expand Up @@ -133,10 +127,6 @@ def get_abi_tag() -> str | None:
return abi


def safer_name(name: str) -> str:
return safe_name(name).replace("-", "_")


def safer_version(version: str) -> str:
return safe_version(version).replace("-", "_")

Expand Down Expand Up @@ -294,7 +284,7 @@ def _validate_py_limited_api(self) -> None:
raise ValueError(
f"`py_limited_api={self.py_limited_api!r}` not supported. "
"`Py_LIMITED_API` is currently incompatible with "
f"`Py_GIL_DISABLED` ({sys.abiflags=!r}). "
"`Py_GIL_DISABLED`."
"See https://github.com/python/cpython/issues/111506."
)

Expand Down
2 changes: 1 addition & 1 deletion contrib/python/setuptools/py3/ya.make
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

PY3_LIBRARY()

VERSION(75.8.0)
VERSION(75.8.1)

LICENSE(MIT)

Expand Down

0 comments on commit 8cba1a8

Please sign in to comment.