cloudenvy/cloudenvy — pull request #34 by jakedahn (2012-10-28 03:50:31+00:00)
Title: Lack of environment not handled well

I have a single named environment built, but if I forget to use that name when I call 'envy ssh' I get a nasty traceback. I would expect this to be presented nicely.

% envy ssh
Traceback (most recent call last):
File "/Users/bcwaldon/src/envy/devstack/.venv/bin/envy", line 8, in
load_entry_point('cloudenvy==0.1.0', 'console_scripts', 'envy')()
File "/Users/bcwaldon/src/envy/devstack/.venv/lib/python2.7/site-packages/cloudenvy/main.py", line 389, in main
args.func(args)
File "/Users/bcwaldon/src/envy/devstack/.venv/lib/python2.7/site-packages/cloudenvy/main.py", line 290, in envy_ssh
if envy.ip():
File "/Users/bcwaldon/src/envy/devstack/.venv/lib/python2.7/site-packages/cloudenvy/envy.py", line 51, in ip
self._ip = self.cloud_api.find_ip(self.server().id)
AttributeError: 'NoneType' object has no attribute 'id'
% envy list
ENVys for your project: ['devstack-BFV']