mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-06 20:24:30 +08:00
Add an upstream_repository field to METADATA.toml (#10487)
Closes: #10478
This commit is contained in:
@@ -246,8 +246,9 @@ async def get_github_repo_info(session: aiohttp.ClientSession, pypi_info: PypiIn
|
||||
|
||||
Else, return None.
|
||||
"""
|
||||
project_urls = pypi_info.info.get("project_urls", {}).values()
|
||||
for project_url in project_urls:
|
||||
# project_urls can be None in the downloaded JSON.
|
||||
project_url_dict = pypi_info.info.get("project_urls") or {}
|
||||
for project_url in project_url_dict.values():
|
||||
assert isinstance(project_url, str)
|
||||
split_url = urllib.parse.urlsplit(project_url)
|
||||
if split_url.netloc == "github.com" and not split_url.query and not split_url.fragment:
|
||||
|
||||
Reference in New Issue
Block a user