spack checksum: do not add expand=False to wheels (#44118)

This commit is contained in:
Adam J. Stewart 2024-05-13 10:01:47 +02:00 committed by GitHub
parent 32b3e91ef7
commit 725f427f25
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -21,16 +21,6 @@ def get_version_lines(version_hashes_dict: dict, url_dict: Optional[dict] = None
version_lines = []
for v, h in version_hashes_dict.items():
expand_arg = ""
# Extract the url for a version if url_dict is provided.
url = ""
if url_dict is not None and v in url_dict:
url = url_dict[v]
# Add expand_arg since wheels should not be expanded during stanging
if url.endswith(".whl") or ".whl#" in url:
expand_arg = ", expand=False"
version_lines.append(f' version("{v}", sha256="{h}"{expand_arg})')
version_lines.append(f' version("{v}", sha256="{h}")')
return "\n".join(version_lines)