Skip to content

Commit 0095d38

Browse files
committed
revert
1 parent e166034 commit 0095d38

File tree

3 files changed

+5
-13
lines changed

3 files changed

+5
-13
lines changed

python/private/pypi/hub_builder.bzl

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -536,9 +536,8 @@ def _whl_repo(
536536
target_platforms = src.target_platforms if is_multiple_versions else []
537537
return struct(
538538
repo_name = pypi_repo_name(
539-
whl_name = normalize_name(src.distribution),
540-
target_platforms = target_platforms,
541-
extras = src.extras,
539+
normalize_name(src.distribution),
540+
*target_platforms
542541
),
543542
args = args,
544543
config_setting = whl_config_setting(
@@ -568,7 +567,7 @@ def _whl_repo(
568567
]
569568

570569
return struct(
571-
repo_name = whl_repo_name(src.filename, src.sha256, extras = src.extras),
570+
repo_name = whl_repo_name(src.filename, src.sha256),
572571
args = args,
573572
config_setting = whl_config_setting(
574573
version = python_version,

python/private/pypi/parse_requirements.bzl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -274,7 +274,6 @@ def _package_srcs(
274274
sha256 = dist.sha256,
275275
url = dist.url,
276276
yanked = dist.yanked,
277-
extras = requirement(r.requirement_line).extras,
278277
),
279278
)
280279

python/private/pypi/whl_repo_name.bzl

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
load("//python/private:normalize_name.bzl", "normalize_name")
1919
load(":parse_whl_name.bzl", "parse_whl_name")
2020

21-
def whl_repo_name(filename, sha256, extras = []):
21+
def whl_repo_name(filename, sha256):
2222
"""Return a valid whl_library repo name given a distribution filename.
2323
2424
Args:
@@ -59,12 +59,9 @@ def whl_repo_name(filename, sha256, extras = []):
5959
elif version:
6060
parts.insert(1, version)
6161

62-
if extras:
63-
parts.extend(sorted([e for e in extras if e]))
64-
6562
return "_".join(parts)
6663

67-
def pypi_repo_name(whl_name, target_platforms = [], extras = []):
64+
def pypi_repo_name(whl_name, *target_platforms):
6865
"""Return a valid whl_library given a requirement line.
6966
7067
Args:
@@ -79,7 +76,4 @@ def pypi_repo_name(whl_name, target_platforms = [], extras = []):
7976
]
8077
parts.extend([p.partition("_")[-1] for p in target_platforms])
8178

82-
if extras:
83-
parts.extend(sorted([e for e in extras if e]))
84-
8579
return "_".join(parts)

0 commit comments

Comments
 (0)