Beispiel #1
0
 def close(self):
     """called before visiting project (i.e set of modules)"""
     if self.linter.is_message_enabled('cyclic-import'):
         graph = self._import_graph_without_ignored_edges()
         vertices = list(graph)
         for cycle in get_cycles(graph, vertices=vertices):
             self.add_message('cyclic-import', args=' -> '.join(cycle))
Beispiel #2
0
 def close(self):
     """called before visiting project (i.e set of modules)"""
     # don't try to compute cycles if the associated message is disabled
     if self.linter.is_message_enabled('cyclic-import'):
         vertices = list(self.import_graph)
         for cycle in get_cycles(self.import_graph, vertices=vertices):
             self.add_message('cyclic-import', args=' -> '.join(cycle))
Beispiel #3
0
 def close(self):
     """called before visiting project (i.e set of modules)"""
     # don't try to compute cycles if the associated message is disabled
     if self.linter.is_message_enabled("cyclic-import"):
         vertices = list(self.import_graph)
         for cycle in get_cycles(self.import_graph, vertices=vertices):
             self.add_message("cyclic-import", args=" -> ".join(cycle))
Beispiel #4
0
 def close(self):
     """called before visiting project (i.e set of modules)"""
     if self.linter.is_message_enabled('cyclic-import'):
         graph = self._import_graph_without_ignored_edges()
         vertices = list(graph)
         for cycle in get_cycles(graph, vertices=vertices):
             self.add_message('cyclic-import', args=' -> '.join(cycle))