Skip to content

Commit cc5f5b2

Browse files
committed
only save to cache if not none
1 parent 83e67c4 commit cc5f5b2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/populate_tox/populate_tox.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,8 @@ def fetch_release(package: str, version: Version) -> Optional[dict]:
104104

105105
url = PYPI_VERSION_URL.format(project=package, version=version)
106106
release = fetch_url(url)
107-
_save_to_cache(package, version, release)
107+
if release is not None:
108+
_save_to_cache(package, version, release)
108109
return release
109110

110111

0 commit comments

Comments
 (0)