Activate pep8 check that _ is imported
Remove the specification in tox.ini that _ is a builtin so that it will no longer assume that _ does not need to be imported. This helps ensure that the _ from i18n is used. Activating this check did flag violations and they were fixed in this patch. Change-Id: Ia7e4c75b2126a67784683d1c22f0e24bc44113a4
This commit is contained in:
parent
a031745047
commit
5db9852314
|
@ -37,6 +37,7 @@ from six.moves import range
|
|||
from six.moves import urllib
|
||||
|
||||
from glance_store import exceptions
|
||||
from glance_store.i18n import _
|
||||
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
|
|
@ -27,6 +27,7 @@ from paste import deploy
|
|||
|
||||
from glance.version import version_info as version
|
||||
from glance_store.common import utils
|
||||
from glance_store.i18n import _
|
||||
|
||||
paste_deploy_opts = [
|
||||
cfg.StrOpt('flavor',
|
||||
|
|
|
@ -28,6 +28,8 @@ except ImportError:
|
|||
from oslo_utils import encodeutils
|
||||
import six
|
||||
|
||||
from glance_store.i18n import _
|
||||
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
|
|
1
tox.ini
1
tox.ini
|
@ -32,5 +32,4 @@ commands = {posargs}
|
|||
# H404 multi line docstring should start with a summary
|
||||
# H405 multi line docstring summary not separated with an empty line
|
||||
ignore = H301,H404,H405
|
||||
builtins = _
|
||||
exclude = .venv,.git,.tox,dist,doc,etc,*glance_store/locale*,*openstack/common*,*lib/python*,*egg,build
|
||||
|
|
Loading…
Reference in New Issue