Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

missing imports #450

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions imagefactory_plugins/IndirectionCloud/IndirectionCloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
# see if we can't move the libvirt stuff as well
# For now we import both
import libxml2
import libvirt
import lxml
import configparser
import tempfile
Expand All @@ -33,6 +34,7 @@
from zope.interface import implementer
from imgfac.ApplicationConfiguration import ApplicationConfiguration
from imgfac.CloudDelegate import CloudDelegate
from imgfac.ImageFactoryException import ImageFactoryException
from imgfac.PersistentImageManager import PersistentImageManager
from imgfac.ReservationManager import ReservationManager

Expand Down Expand Up @@ -299,9 +301,9 @@ def _init_oz(self):
self.guest = oz.GuestFactory.guest_factory(self.tdlobj, self.oz_config, None)
# Oz just selects a random port here - This could potentially collide if we are unlucky
self.guest.listen_port = self.res_mgr.get_next_listen_port()
except libvirtError as e:
except libvirt.libvirtError as e:
raise ImageFactoryException("Cannot connect to libvirt. Make sure libvirt is running. [Original message: %s]" % e.message)
except OzException as e:
except oz.OzException.OzException as e:
if "Unsupported" in e.message:
raise ImageFactoryException("TinMan plugin does not support distro (%s) update (%s) in TDL" % (self.tdlobj.distro, self.tdlobj.update) )
else:
Expand Down