Commit d0be6601 authored by Lukas Fleischer's avatar Lukas Fleischer
Browse files

git-update: Improve error message on invalid pkgbase

When the package base does not match the repository name, we currently
show an error message that only mentions the package base name:

    error: invalid pkgbase: yate-qt4

To the end user this sounds like the package base name is malformed
itself (and we show exactly the same error message when it contains
invalid characters, indeed). Clarify that there is a name mismatch by
also printing the expected value:

    error: invalid pkgbase: yate-qt4, expected: yate4-qt

Inspired by FS#45483.

Signed-off-by: Lukas Fleischer's avatarLukas Fleischer <>
parent 8bd03adb
......@@ -286,7 +286,7 @@ srcinfo = aurinfo.ParseAurinfoFromIterable(srcinfo_raw)
srcinfo_pkgbase = srcinfo._pkgbase['pkgname']
if srcinfo_pkgbase != pkgbase:
die('invalid pkgbase: {:s}'.format(srcinfo_pkgbase))
die('invalid pkgbase: {:s}, expected {:s}'.format(srcinfo_pkgbase, pkgbase))
pkgbase = srcinfo._pkgbase['pkgname']
cur.execute("SELECT ID FROM PackageBases WHERE Name = %s", [pkgbase])
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