pylint/pyreverse/inspector.py
def _imported_module(self, node, mod_path, relative):
        """Notify an imported module, used to analyze dependencies"""
        module = node.root()
        context_name = module.name
        if relative:
            mod_path = "%s.%s" % (".".join(context_name.split(".")[:-1]), mod_path)
        if self.compute_module(context_name, mod_path):
            # handle dependencies
            if not hasattr(module, "depends"):
                module.depends = []
            mod_paths = module.depends
            if mod_path not in mod_paths:
                mod_paths.append(mod_path)
def _imported_module(self, node, mod_path, relative):
        module = node.root()
        context_name = module.name
        if relative:
            mod_path = "%s.%s" % (".".join(context_name.split(".")[:-1]), mod_path)
        if self.compute_module(context_name, mod_path):
            # handle dependencies
            if not hasattr(module, "depends"):
                module.depends = []
            mod_paths = module.depends
            if mod_path not in mod_paths:
                mod_paths.append(mod_path)
def _imported_module ( self , node , mod_path , relative ) : module = node . root ( ) context_name = module . name if relative : mod_path = "%s.%s" % ( "." . join ( context_name . split ( "." ) [ : - 1 ] ) , mod_path ) if self . compute_module ( context_name , mod_path ) : # handle dependencies if not hasattr ( module , "depends" ) : module . depends = [ ] mod_paths = module . depends if mod_path not in mod_paths : mod_paths . append ( mod_path )
Notify an imported module, used to analyze dependencies
Notify an imported module used to analyze dependencies