(cherry picked from commit 74421f42e1e20be040161030c8504fea381917fe)
Brian Coca authored on 2017/01/13 03:08:49... | ... |
@@ -89,7 +89,7 @@ class DocCLI(CLI): |
89 | 89 |
|
90 | 90 |
try: |
91 | 91 |
# if the module lives in a non-python file (eg, win_X.ps1), require the corresponding python file for docs |
92 |
- filename = module_loader.find_plugin(module, mod_type='.py') |
|
92 |
+ filename = module_loader.find_plugin(module, mod_type='.py', ignore_deprecated=True) |
|
93 | 93 |
if filename is None: |
94 | 94 |
display.warning("module %s not found in %s\n" % (module, DocCLI.print_paths(module_loader))) |
95 | 95 |
continue |
... | ... |
@@ -174,7 +174,7 @@ class DocCLI(CLI): |
174 | 174 |
continue |
175 | 175 |
|
176 | 176 |
# if the module lives in a non-python file (eg, win_X.ps1), require the corresponding python file for docs |
177 |
- filename = module_loader.find_plugin(module, mod_type='.py') |
|
177 |
+ filename = module_loader.find_plugin(module, mod_type='.py', ignore_deprecated=True) |
|
178 | 178 |
|
179 | 179 |
if filename is None: |
180 | 180 |
continue |
... | ... |
@@ -221,7 +221,7 @@ class PluginLoader: |
221 | 221 |
self._extra_dirs.append(directory) |
222 | 222 |
self._paths = None |
223 | 223 |
|
224 |
- def find_plugin(self, name, mod_type=''): |
|
224 |
+ def find_plugin(self, name, mod_type='', ignore_deprecated=False): |
|
225 | 225 |
''' Find a plugin named name ''' |
226 | 226 |
|
227 | 227 |
if mod_type: |
... | ... |
@@ -297,7 +297,7 @@ class PluginLoader: |
297 | 297 |
alias_name = '_' + name |
298 | 298 |
# We've already cached all the paths at this point |
299 | 299 |
if alias_name in pull_cache: |
300 |
- if not os.path.islink(pull_cache[alias_name]): |
|
300 |
+ if not ignore_deprecated and not os.path.islink(pull_cache[alias_name]): |
|
301 | 301 |
display.deprecated('%s is kept for backwards compatibility ' |
302 | 302 |
'but usage is discouraged. The module ' |
303 | 303 |
'documentation details page may explain ' |