Open
Description
Create an appliance with no 'node' parameter set. Create a host of that appliance type, and try to list its profile. Kaboom.
list host profile/xml
should probably catch this exception and bail out.
# stack add appliance foo
# stack add host foobar box=default appliance=foo rack=0 rank=33
# stack list host attr foobar | grep node
# stack list host profile foobar
File "/opt/stack/bin/stack", line 245, in run_command
rc = command.runWrapper(name, args[i:])
File "/opt/stack/lib/python2.6/site-packages/stack/commands/command.py", line 2304, in runWrapper
rc = self.run(self._params, self._args)
File "/opt/stack/lib/python2.6/site-packages/stack/commands/list/host/profile/__init__.py", line 212, in run
xmlinput = self.command('list.host.xml', [ host ])
File "/opt/stack/lib/python2.6/site-packages/stack/commands/command.py", line 1728, in command
self.rc = o.runWrapper(name, args, self.level + 1)
File "/opt/stack/lib/python2.6/site-packages/stack/commands/command.py", line 2304, in runWrapper
rc = self.run(self._params, self._args)
File "/opt/stack/lib/python2.6/site-packages/stack/commands/list/host/xml/__init__.py", line 136, in run
args = [ attrs['node'] ]
stack.commands.list.host.profile: KeyError -- 'node'