autohelp: add a module blacklisting mechanism

Change-Id: I932bc5ad740c9eaee3d1db05462ccb2c2a2779a7
This commit is contained in:
Gauvain Pocentek 2014-09-06 08:44:39 +02:00
parent c5af452d8c
commit b4cb74cb07
2 changed files with 10 additions and 2 deletions

View File

@ -9,8 +9,9 @@ Release notes
* ``autohelp.py``: Improve sanitizer, better support for i18n in
projects, allow setting of title name for tables.
* ``autohelp-wrapper``: Smarter handling of the manuals repo and environment
setup, add support for the ``create`` subcommand, add support for
offline/fast operation.
setup, add support for the ``create`` subcommand.
* ``autohelp-wrapper``: Add support for offline/fast operation.
* ``autohelp-wrapper``: Add a module blacklisting mechanism.
* ``diff_branches.py``: Updated output format.
0.18.1

View File

@ -37,6 +37,11 @@ from hooks import HOOKS # noqa
EXTENSIONS = ['oslo.messaging', 'oslo.db']
IGNORE = ['trove.guestagent.datastore.postgresql.manager',
'trove.guestagent.datastore.postgresql.service.root',
'trove.guestagent.datastore.postgresql.service.users',
'trove.guestagent.datastore.postgresql.service.database']
BASE_XML = '''<?xml version="1.0" encoding="UTF-8"?>
<para xmlns="http://docbook.org/ns/docbook"
version="5.0">
@ -127,6 +132,8 @@ def import_modules(repo_location, package_name, verbose=0):
modname = '.'.join(modname)
if modname.endswith('.__init__'):
modname = modname[:modname.rfind(".")]
if modname in IGNORE:
continue
try:
module = importlib.import_module(modname)
if verbose >= 1: