Ejemplo n.º 1
0
 def _reschedule_job(self, fw_object):
     unmatched_dependencies = get_unmatched_dependencies([fw_object], self.DEPENDENCIES)
     logging.debug('{} rescheduled due to unmatched dependencies:\n {}'.format(fw_object.get_virtual_file_paths(), unmatched_dependencies))
     fw_object.scheduled_analysis = schedule_dependencies(fw_object.scheduled_analysis, unmatched_dependencies, self.NAME)
     fw_object.analysis_dependency = fw_object.analysis_dependency.union(set(unmatched_dependencies))
     logging.debug('new schedule for {}:\n {}\nAnalysis Dependencies: {}'.format(
         fw_object.get_virtual_file_paths(), fw_object.scheduled_analysis, fw_object.analysis_dependency))
Ejemplo n.º 2
0
 def compare(self, fo_list):
     '''
     This function is called by the compare module.
     '''
     missing_deps = get_unmatched_dependencies(fo_list, self.DEPENDENCIES)
     if len(missing_deps) > 0:
         return {'Compare Skipped': {'all': 'Required analysis not present: {}'.format(missing_deps)}}
     else:
         return self.compare_function(fo_list)
Ejemplo n.º 3
0
 def unmatched_dependency_test(self, processed_list, dependencies,
                               out_list):
     unmatched_dependencies = get_unmatched_dependencies(
         processed_list, dependencies)
     self.assertEqual(unmatched_dependencies, out_list,
                      'unmatched dependency list not correct')
Ejemplo n.º 4
0
 def _dependencies_are_fulfilled(self, fo):
     return get_unmatched_dependencies([fo], self.DEPENDENCIES) == []