mirror of
https://github.com/astral-sh/uv.git
synced 2025-08-31 15:57:26 +00:00
Use sha256 checksum from GitHub API for GraalPy releases (#14779)
## Summary Follow #14078, use GitHub generated sha256 for GraalPy releases too. ## Test Plan ```console uv run ./crates/uv-python/fetch-download-metadata.py ```
This commit is contained in:
parent
8ed86a6dcd
commit
9983273289
1 changed files with 5 additions and 0 deletions
|
@ -607,6 +607,9 @@ class GraalPyFinder(Finder):
|
|||
platform = self._normalize_os(m.group(1))
|
||||
arch = self._normalize_arch(m.group(2))
|
||||
libc = "gnu" if platform == "linux" else "none"
|
||||
sha256 = None
|
||||
if digest := asset["digest"]:
|
||||
sha256 = digest.removeprefix("sha256:")
|
||||
download = PythonDownload(
|
||||
release=0,
|
||||
version=python_version,
|
||||
|
@ -619,6 +622,7 @@ class GraalPyFinder(Finder):
|
|||
implementation=self.implementation,
|
||||
filename=asset["name"],
|
||||
url=url,
|
||||
sha256=sha256,
|
||||
)
|
||||
# Only keep the latest GraalPy version of each arch/platform
|
||||
if (python_version, arch, platform) not in results:
|
||||
|
@ -633,6 +637,7 @@ class GraalPyFinder(Finder):
|
|||
return self.PLATFORM_MAPPING.get(os, os)
|
||||
|
||||
async def _fetch_checksums(self, downloads: list[PythonDownload], n: int) -> None:
|
||||
downloads = list(filter(lambda d: not d.sha256, downloads))
|
||||
for idx, batch in enumerate(batched(downloads, n)):
|
||||
logging.info("Fetching GraalPy checksums: %d/%d", idx * n, len(downloads))
|
||||
checksum_requests = []
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue