FS#71205 - [namcap] crashes if missing source entry

Attached to Project: Arch Linux
Opened by RoundCube (RoundCube) - Thursday, 10 June 2021, 00:38 GMT
Last edited by Eli Schwartz (eschwartz) - Thursday, 10 June 2021, 00:47 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

If a PKGBUILD has no source=() entry, namcap crashes.

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

Closed by  Eli Schwartz (eschwartz)
Thursday, 10 June 2021, 00:47 GMT
Reason for closing:  Duplicate
Additional comments about closing:   FS#65042   FS#68358 

Loading...