Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#73291 - [namcap] crash when PKGBUILD does not have the source array

Attached to Project: Arch Linux
Opened by Adler Jonas Gross (Betal) - Saturday, 08 January 2022, 06:37 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Monday, 07 February 2022, 07:38 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To No-one
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

PKGBUILDs without source array cause namcap to crash.
Example PKGBUILD: core/base

Package version: 3.2.10-5

Steps to reproduce:
$ namcap PKGBUILD
Traceback (most recent call last):
File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/usr/lib/python3.10/site-packages/namcap.py", line 247, in <module>
process_pkgbuild(package, active_modules)
File "/usr/lib/python3.10/site-packages/namcap.py", line 148, in process_pkgbuild
ret = rule.analyze(pkginfo, package)
File "/usr/lib/python3.10/site-packages/Namcap/rules/makedepends.py", line 59, in analyze
for s in pkginfo["source"]:
File "/usr/lib/python3.10/site-packages/Namcap/package.py", line 128, in __getitem__
return self._data[self.canonical_varname(key)]
KeyError: 'source'


Already fixed upstream: https://gitlab.archlinux.org/pacman/namcap/-/commit/05dbc1f226980a46001ed472ca8e34c83c8128c0
This task depends upon

Closed by  Sven-Hendrik Haase (Svenstaro)
Monday, 07 February 2022, 07:38 GMT
Reason for closing:  Duplicate
Additional comments about closing:  2022-01-08: A task closure has been requested. Reason for request: Duplicate of https://bugs.archlinux.org/task/65042

Loading...