version_added for deprecated modules (#36)
* version_added for deprecated modules Modules are deprecated by renaming so they start with "_". This means we will not find an existing module with that name, so look up the original name, i.e. without the leading '_'. * Deal with aliased/symlinked modules
This commit is contained in:
parent
f883b33441
commit
60e8cf9aa7
1 changed files with 5 additions and 1 deletions
|
@ -181,7 +181,11 @@ class ModuleValidator(Validator):
|
|||
return False
|
||||
|
||||
def _is_new_module(self):
|
||||
return not module_loader.has_plugin(self.name)
|
||||
if self.name.startswith("_") and not os.path.islink(self.name):
|
||||
# This is a deprecated module, so look up the *old* name
|
||||
return not module_loader.has_plugin(self.name[1:])
|
||||
else:
|
||||
return not module_loader.has_plugin(self.name)
|
||||
|
||||
def _check_interpreter(self, powershell=False):
|
||||
if powershell:
|
||||
|
|
Loading…
Reference in a new issue