services.py: check for missing repositories

This commit is contained in:
Drew DeVault 2020-11-28 09:59:36 -05:00
parent 9154800871
commit de0182c2c1
1 changed files with 2 additions and 0 deletions

View File

@ -130,6 +130,8 @@ class GitService(SrhtService):
"repoId": repo_id,
},
})
if not r["data"]["repository"]:
raise Exception(f"git.sr.ht did not find repo ID {repo_id} (requesting on behalf of {user.username})")
manifests = dict()
if r["data"]["repository"]["multiple"]:
for ent in r["data"]["repository"]["multiple"]["object"]\