summaryrefslogtreecommitdiff
path: root/setuptools/command
diff options
context:
space:
mode:
authorAnderson Bravalheri <andersonbravalheri@gmail.com>2023-02-01 14:02:34 +0000
committerAnderson Bravalheri <andersonbravalheri@gmail.com>2023-02-01 14:02:34 +0000
commit51bf7563d1513ec3a2edbbcf00a533f85cf26d66 (patch)
tree74742dd32aa2057be4f6793ef96c8a5b7b184730 /setuptools/command
parent3736cbc2bdaef3fa4dfbdf59dac69be42bf8aa15 (diff)
downloadpython-setuptools-git-51bf7563d1513ec3a2edbbcf00a533f85cf26d66.tar.gz
Allow None to be passed to egg_basename
Diffstat (limited to 'setuptools/command')
-rw-r--r--setuptools/command/egg_info.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/setuptools/command/egg_info.py b/setuptools/command/egg_info.py
index 30ecf1dd..afcde5a2 100644
--- a/setuptools/command/egg_info.py
+++ b/setuptools/command/egg_info.py
@@ -776,11 +776,11 @@ def get_pkg_info_revision():
return 0
-def _egg_basename(egg_name, egg_version, py_version=PY_MAJOR, platform=None):
+def _egg_basename(egg_name, egg_version, py_version=None, platform=None):
"""Compute filename of the output egg. Private API."""
name = _normalization.filename_component(egg_name)
version = _normalization.filename_component(egg_version)
- egg = f"{name}-{version}-py{py_version}"
+ egg = f"{name}-{version}-py{py_version or PY_MAJOR}"
if platform:
egg += f"-{platform}"
return egg