From 5aaabd39dd09cc10a5b24dab3267bb60eb9cec7c Mon Sep 17 00:00:00 2001 From: Hiroshi Noji Date: Tue, 27 Jan 2015 17:17:13 +0900 Subject: [PATCH] Check if at least 1 task is generated in _generate_task_ --- maflib/core.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/maflib/core.py b/maflib/core.py index da26764..150543b 100644 --- a/maflib/core.py +++ b/maflib/core.py @@ -160,11 +160,20 @@ def _generate_tasks(self, call_object): parameter_lists = new_lists + task_is_generated = False for parameter_list in parameter_lists: for parameter in call_object.parameters: if any(p.conflict_with(parameter) for p in parameter_list): continue self._generate_task(call_object, parameter_list, parameter) + task_is_generated = True + + if not task_is_generated: + source = ' '.join(call_object.source) + target = ' '.join(call_object.target) + waflib.Logs.warn( + 'No task is generated for %s -> %s. Parameter setting for this task might be unintended?' % + (source, target)) def _generate_task(self, call_object, source_parameter, parameter): # Create target parameter by merging source parameter and task-gen