record the type name, if there is no such type

Signed-off-by: Nico Schottelius <nico@bento.schottelius.org>
This commit is contained in:
Nico Schottelius 2013-09-02 11:30:22 +02:00
commit 73338c330b
2 changed files with 5 additions and 4 deletions

View file

@ -177,8 +177,8 @@ class Emulator(object):
# Raises an error, if object cannot be created
try:
cdist_object = self.cdist_object.object_from_name(requirement)
except core.cdist_type.NoSuchTypeError:
self.log.error("%s requires object %s with non-existing type at %s" % (self.cdist_object.name, requirement, self.object_source))
except core.cdist_type.NoSuchTypeError as e:
self.log.error("%s requires object %s, but type %s does not exist (definded at %s)" % (self.cdist_object.name, requirement, e.name, self.object_source))
raise