Skip to content

Commit bd36934

Browse files
authored
always set forceZip64=True
1 parent 00765de commit bd36934

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

tools/wheelmaker.py

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -107,11 +107,9 @@ def __init__(
107107
distribution_prefix: str,
108108
strip_path_prefixes=None,
109109
compression=zipfile.ZIP_DEFLATED,
110-
force_zip64=False,
111110
**kwargs,
112111
):
113112
self._distribution_prefix = distribution_prefix
114-
self._force_zip64 = force_zip64
115113

116114
self._strip_path_prefixes = strip_path_prefixes or []
117115
# Entries for the RECORD file as (filename, hash, size) tuples.
@@ -156,7 +154,7 @@ def arcname_from(name):
156154
hash = hashlib.sha256()
157155
size = 0
158156
with open(real_filename, "rb") as fsrc:
159-
with self.open(zinfo, "w", force_zip64=self._force_zip64) as fdst:
157+
with self.open(zinfo, "w", force_zip64=True) as fdst:
160158
while True:
161159
block = fsrc.read(2**20)
162160
if not block:
@@ -243,7 +241,6 @@ def __init__(
243241
compress,
244242
outfile=None,
245243
strip_path_prefixes=None,
246-
force_zip64=False,
247244
):
248245
self._name = name
249246
self._version = normalize_pep440(version)
@@ -253,7 +250,6 @@ def __init__(
253250
self._platform = platform
254251
self._outfile = outfile
255252
self._strip_path_prefixes = strip_path_prefixes
256-
self._force_zip64 = force_zip64
257253
self._compress = compress
258254
self._wheelname_fragment_distribution_name = escape_filename_distribution_name(
259255
self._name
@@ -272,7 +268,6 @@ def __enter__(self):
272268
distribution_prefix=self._distribution_prefix,
273269
strip_path_prefixes=self._strip_path_prefixes,
274270
compression=zipfile.ZIP_DEFLATED if self._compress else zipfile.ZIP_STORED,
275-
force_zip64=self._force_zip64,
276271
)
277272
return self
278273

@@ -483,11 +478,6 @@ def parse_args() -> argparse.Namespace:
483478
type=Path,
484479
help="Pass in the stamp info file for stamping",
485480
)
486-
output_group.add_argument(
487-
"--force_zip64",
488-
action="store_true",
489-
help="Forces usage of zip64",
490-
)
491481

492482
return parser.parse_args(sys.argv[1:])
493483

@@ -546,7 +536,6 @@ def main() -> None:
546536
outfile=arguments.out,
547537
strip_path_prefixes=strip_prefixes,
548538
compress=not arguments.no_compress,
549-
force_zip64=arguments.force_zip64,
550539
) as maker:
551540
for package_filename, real_filename in all_files:
552541
maker.add_file(package_filename, real_filename)

0 commit comments

Comments
 (0)