Bug 865726

Summary: Traceback when getting test run build
Product: [Fedora] Fedora Reporter: Petr Šplíchal <psplicha>
Component: python-nitrateAssignee: Petr Šplíchal <psplicha>
Status: CLOSED WORKSFORME QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: ohudlick, psplicha
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-12-06 11:08:52 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Petr Šplíchal 2012-10-12 09:16:04 UTC
Description of problem:
>>> print TestRun(47717).build
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.6/site-packages/nitrate/api.py", line 192, in getter
    self._get()
  File "/usr/lib/python2.6/site-packages/nitrate/api.py", line 2682, in _get
    self._build = Build(testrunhash["build_id"])
KeyError: 'build_id'

Version-Release number of selected component (if applicable):
python-nitrate-0.9-0.el6.noarch

Comment 1 Petr Šplíchal 2012-12-06 11:08:52 UTC
Looks like this has been fixed on the server side:

>>> print TestRun(47717).build
[INFO] Fetching test run TR#47717
[DEBUG] Initializing test run TR#47717
[DEBUG] {'auto_update_run_status': False,
 'build': 'unspecified',
 'build_id': 1156,
 'case_run_status': '2:65',
...

The 'build_id' key is now present in the testrunhash.