Bug 849818 - Watchdogs grid doesn't handle watchdogs with NULL recipe_task_id
Watchdogs grid doesn't handle watchdogs with NULL recipe_task_id
Product: Beaker
Classification: Community
Component: web UI (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified (vote)
: 0.9.3
: ---
Assigned To: Dan Callaghan
Depends On:
  Show dependency treegraph
Reported: 2012-08-20 23:00 EDT by Dan Callaghan
Modified: 2012-09-06 00:38 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-09-06 00:38:51 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Dan Callaghan 2012-08-20 23:00:01 EDT
On visiting the list of watchdogs at /watchdogs/:

2012-08-20 22:57:50,598 cherrypy.msg INFO HTTP: Page handler: <bound method Watchdogs.index of <bkr.server.watchdog.Watchdogs object at 0x7f48da683a10>>
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/CherryPy-2.3.0-py2.6.egg/cherrypy/_cphttptools.py", line 121, in _run
  File "/usr/lib/python2.6/site-packages/CherryPy-2.3.0-py2.6.egg/cherrypy/_cphttptools.py", line 264, in main
    body = page_handler(*virtual_path, **self.params)
  File "<string>", line 3, in index
  File "/usr/lib/python2.6/site-packages/turbogears/controllers.py", line 361, in expose
    *args, **kw)
  File "<generated code>", line 0, in run_with_transaction
  File "build/lib/bkr/server/templates/my_paginate_datagrid.py", line 165, in _pull
  File "/usr/lib/python2.6/site-packages/turbogears/widgets/datagrid.py", line 66, in get_field
    return self.getter(row)
  File "/usr/lib/python2.6/site-packages/bkr/server/watchdog.py", line 30, in <lambda>
    col(name='task_name', getter=lambda x: x.recipetask.link, title="Task Name"),
AttributeError: 'NoneType' object has no attribute 'link'
Error in code generated from template file 'build/lib/bkr/server/templates/grid.kid'
Comment 1 Dan Callaghan 2012-08-21 20:57:12 EDT
The watchdog.recipe_task_id column can be NULL while the recipe is in Waiting state, waiting for the system to reboot and the first task to be started. This is a new thing, as of commit 56c72d19 for bug 835373.
Comment 2 Dan Callaghan 2012-08-21 22:34:05 EDT
On Gerrit: http://gerrit.beaker-project.org/1299
Comment 4 Raymond Mancy 2012-08-26 21:18:50 EDT
This is too hard to test on a live system because of the timing constraints
Comment 5 Dan Callaghan 2012-09-06 00:38:51 EDT
Beaker 0.9.3 has been released.

Note You need to log in before you can comment on or make changes to this bug.