Commit 7bb1fa24 authored by Christophe Dumez's avatar Christophe Dumez

- fixed bug #303 : "Business Template silently ignores non existant path during build"


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@9015 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent c7621e4d
...@@ -93,6 +93,11 @@ class BusinessTemplateMissingDependency(Exception): ...@@ -93,6 +93,11 @@ class BusinessTemplateMissingDependency(Exception):
""" """
pass pass
class BusinessTemplateResolveError(Exception):
""" Exception raised when a dependency is missing
"""
pass
def removeAll(entry): def removeAll(entry):
''' '''
Remove all files and directories under 'entry'. Remove all files and directories under 'entry'.
...@@ -747,10 +752,7 @@ class PathTemplateItem(ObjectTemplateItem): ...@@ -747,10 +752,7 @@ class PathTemplateItem(ObjectTemplateItem):
try: try:
obj = folder._getOb(id) obj = folder._getOb(id)
except AttributeError: except AttributeError:
# XXX FIXME raise BusinessTemplateResolveError, "Could not resolve '%s' during business template processing." % id
LOG("WARNING!", 100,
"Can not resolve '%s' during business template installation." % id)
return []
return self._resolvePath(obj, relative_url_list + [id], id_list[1:]) return self._resolvePath(obj, relative_url_list + [id], id_list[1:])
path_list = [] path_list = []
for object_id in fnmatch.filter(folder.objectIds(), id): for object_id in fnmatch.filter(folder.objectIds(), id):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment