python: urls return [] if not pypi

This commit is contained in:
Wouter Deconinck 2024-08-10 17:13:07 -05:00 committed by GitHub
parent c0e64718c7
commit 868cb442e9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -365,7 +365,7 @@ def urls(cls) -> Optional[List[str]]:
pypi = "/".join([name, file.replace("-", "_", name_dash_count)])
urls.append(f"https://files.pythonhosted.org/packages/source/{pypi[0]}/{pypi}")
return urls
return None
return []
@lang.classproperty
def list_url(cls) -> Optional[str]: # type: ignore[override]