Bug 831284 - [BUG] requesting nfs method when there is no nfs method causes traceback in beakerd
Summary: [BUG] requesting nfs method when there is no nfs method causes traceback in b...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Beaker
Classification: Retired
Component: scheduler
Version: 0.9
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Dan Callaghan
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-06-12 16:36 UTC by Bill Peck
Modified: 2012-08-13 10:25 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-08-13 10:25:23 UTC
Embargoed:


Attachments (Terms of Use)

Description Bill Peck 2012-06-12 16:36:16 UTC
Description of problem:

Our default install method is nfs but if you only import a tree via http it will produce a traceback.

Version-Release number of selected component (if applicable):
0.9.0

How reproducible:
Everytime

Steps to Reproduce:
1. Import only http
2. submit a job with bkr workflow-simple and don't specify install method.

Additional info:

2012-06-12 12:28:00,288 beakerd INFO scheduled_recipes: RS:10
2012-06-12 12:28:00,404 beakerd ERROR Failed to provision recipeid 10
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/bkr/server/tools/beakerd.py", line 465, in scheduled_recipes
    recipe.provision()
  File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 4859, in provision
    recipe=self, ks_appends=ks_appends)
  File "/usr/lib/python2.6/site-packages/bkr/server/kickstart.py", line 156, in generate_kickstart
    result = template.render(context)
  File "/usr/lib64/python2.6/site-packages/jinja2/environment.py", line 669, in render
    return self.environment.handle_exception(exc_info, True)
  File "/usr/lib/python2.6/site-packages/bkr/server/kickstarts/RedHatEnterpriseLinux7", line 7, in top-level template code
    {{ snippet('install_method') }}
  File "/usr/lib64/python2.6/site-packages/jinja2/sandbox.py", line 251, in call
    return __context.call(__obj, *args, **kwargs)
  File "/usr/lib/python2.6/site-packages/bkr/server/kickstart.py", line 143, in snippet
    return template.render(context)
  File "/usr/lib64/python2.6/site-packages/jinja2/environment.py", line 669, in render
    return self.environment.handle_exception(exc_info, True)
  File "/usr/lib/python2.6/site-packages/bkr/server/snippets/install_method", line 2, in top-level template code
    {% set parsed_url = url|parsed_url %}
  File "/usr/lib64/python2.6/urlparse.py", line 129, in urlparse
    tuple = urlsplit(url, scheme, allow_fragments)
  File "/usr/lib64/python2.6/urlparse.py", line 168, in urlsplit
    i = url.find(':')
AttributeError: 'NoneType' object has no attribute 'find'
2012-06-12 12:28:00,454 beakerd DEBUG Exiting scheduled_recipes routine

Comment 1 Dan Callaghan 2012-08-13 10:25:23 UTC
I'm pretty sure the only possible cause of this stack trace is that there are *no* URLs in the lab for this distro tree (i.e. url_in_lab returned None).

As of commit 86efbdbb there is a proper exception for it ('No usable URL found...') but it would still fail. There's not really much Beaker can do in this case. I think it can only happen if the distro tree was removed from the lab after it was scheduled but before the dead recipes routine could pick it up.


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