diff options
-rwxr-xr-x | src/flufigut.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/flufigut.py b/src/flufigut.py index 8decd90..d17a03a 100755 --- a/src/flufigut.py +++ b/src/flufigut.py @@ -157,15 +157,15 @@ class Planet: self._unassigned_components = [] def __get_worker(self, comp_name): - matched_prefix_len = 0 + match_prefix_len = 0 match = None for search_string, pattern in self._desc.worker_patterns.items(): if pattern.is_prefix: if comp_name.startswith(search_string): - if len(search_string) == matched_prefix_len: + if len(search_string) == match_prefix_len: raise Exception("component '%s': both patterns '%s' of worker '%s' and '%s' of worker '%s' match the component name and have the same length" % (comp_name, match.pattern, match.worker, pattern.pattern, pattern.worker)) - elif len(search_string) > matched_prefix_len: + elif len(search_string) > match_prefix_len: match_prefix_len = len(search_string) match = pattern else: @@ -550,6 +550,7 @@ if __name__ == '__main__': sys.exit(1) p.toXML('../templates/flumotion/', 'output/planet.xml') + print("****************************************************") print("** atmosphere **") print("**") |