gentoo / tatt

[MIRROR] arch testing tool
https://gitweb.gentoo.org/proj/tatt.git
GNU General Public License v2.0
11 stars 14 forks source link

Catch PortageKeyError when atom wasn't found #47

Open Whissi opened 6 years ago

Whissi commented 6 years ago
 # tatt -b 652296
Bugnumber:  652296
Stabilization bug detected.
Jobname: Apache-AuthCookie-652296
Found the following package atom : =dev-perl/Apache-AuthCookie-3.270.0-r1
Traceback (most recent call last):
  File "/usr/lib/python-exec/python3.5/tatt", line 202, in <module>
    kw = port.aux_get(dep_getcpv(p.packageString()), ["KEYWORDS"])
  File "/usr/lib/python3.5/site-packages/portage/dbapi/porttree.py", line 613, in aux_get
    raise PortageKeyError(mycpv)
portage.exception.PortageKeyError: 'dev-perl/Apache-AuthCookie-3.270.0-r1'

My repository was out of date and didn't contain dev-perl/Apache-AuthCookie-3.270.0-r1. I think this can be improved and catched to display an actionable error message.