Verified Commit 5a1bb85b authored by Jan Alexander Steffens (heftig)'s avatar Jan Alexander Steffens (heftig)
Browse files

db-update: Use pkgname if pkgbase is missing

parent 4f38fcf5
...@@ -135,7 +135,10 @@ async def main() -> int: ...@@ -135,7 +135,10 @@ async def main() -> int:
pkgbases = {r: {} for r in packages.keys()} pkgbases = {r: {} for r in packages.keys()}
for repo, ps in sorted(packages.items()): for repo, ps in sorted(packages.items()):
for pkgpath, (pkginfo, pkgfiles) in ps.items(): for pkgpath, (pkginfo, pkgfiles) in ps.items():
pkgbase = pkginfo["pkgbase"][0] try:
pkgbase = pkginfo["pkgbase"][0]
except KeyError:
pkgbase = pkginfo["pkgname"][0]
if pkgbase not in pkgbases[repo]: if pkgbase not in pkgbases[repo]:
pkgbases[repo][pkgbase] = { pkgbases[repo][pkgbase] = {
"version": pkginfo["pkgver"][0], "version": pkginfo["pkgver"][0],
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment