From e278a56d12843f0278ef976cb428243e9144cf80 Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Sat, 1 Jun 2024 04:20:00 +0000 Subject: [PATCH] Ignore yanked versions in fetchCrate --- nix_update/version/crate.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nix_update/version/crate.py b/nix_update/version/crate.py index 1a312ea..e399938 100644 --- a/nix_update/version/crate.py +++ b/nix_update/version/crate.py @@ -15,4 +15,6 @@ def fetch_crate_versions(url: ParseResult) -> list[Version]: info(f"fetch {crate_url}") resp = urllib.request.urlopen(crate_url) data = json.loads(resp.read()) - return [Version(version["num"]) for version in data["versions"]] + return [ + Version(version["num"]) for version in data["versions"] if not version["yanked"] + ]