Fix and enable gating on H306
Fix fallout of Hacking check: Imports should be in alphabetical order Change-Id: I179711c8448208592490ffa47d51419779940014
This commit is contained in:
parent
f950af8e4f
commit
d6114f914c
@ -36,8 +36,8 @@ from glance.common import utils
|
||||
from glance.common import wsgi
|
||||
import glance.db
|
||||
from glance import image_cache
|
||||
import glance.openstack.common.log as logging
|
||||
from glance import notifier
|
||||
import glance.openstack.common.log as logging
|
||||
import glance.registry.client.v1.api as registry
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
@ -19,9 +19,9 @@ from oslo.config import cfg
|
||||
import webob.exc
|
||||
|
||||
from glance.common import exception
|
||||
from glance.openstack.common import excutils
|
||||
from glance.common import utils
|
||||
import glance.db
|
||||
from glance.openstack.common import excutils
|
||||
import glance.openstack.common.log as logging
|
||||
import glance.registry.client.v1.api as registry
|
||||
import glance.store
|
||||
|
@ -13,8 +13,8 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from glance.api.v2 import images
|
||||
from glance.api.v2 import image_members
|
||||
from glance.api.v2 import images
|
||||
from glance.api.v2 import tasks
|
||||
from glance.common import wsgi
|
||||
|
||||
|
@ -22,17 +22,17 @@ import webob.exc
|
||||
|
||||
from oslo.config import cfg
|
||||
|
||||
from glance.api import policy
|
||||
from glance.common import exception
|
||||
from glance.common import utils
|
||||
from glance.common import wsgi
|
||||
import glance.db
|
||||
import glance.gateway
|
||||
import glance.notifier
|
||||
import glance.schema
|
||||
import glance.store
|
||||
from glance.api import policy
|
||||
from glance.common import wsgi
|
||||
from glance.common import exception
|
||||
from glance.common import utils
|
||||
import glance.openstack.common.jsonutils as json
|
||||
from glance.openstack.common import timeutils
|
||||
import glance.schema
|
||||
import glance.store
|
||||
|
||||
CONF = cfg.CONF
|
||||
|
||||
|
@ -39,8 +39,8 @@ if os.path.exists(os.path.join(possible_topdir, 'glance', '__init__.py')):
|
||||
sys.path.insert(0, possible_topdir)
|
||||
|
||||
from glance.common import config
|
||||
from glance.common import wsgi
|
||||
from glance.common import exception
|
||||
from glance.common import wsgi
|
||||
from glance.openstack.common import log
|
||||
import glance.store
|
||||
|
||||
|
@ -41,9 +41,9 @@ import fixtures
|
||||
from sqlalchemy import create_engine
|
||||
import testtools
|
||||
|
||||
from glance import tests as glance_tests
|
||||
from glance.common import utils
|
||||
from glance.openstack.common import units
|
||||
from glance import tests as glance_tests
|
||||
from glance.tests import utils as test_utils
|
||||
|
||||
execute, get_unused_port = test_utils.execute, test_utils.get_unused_port
|
||||
|
@ -15,8 +15,8 @@
|
||||
|
||||
from glance.api import CONF
|
||||
import glance.db.registry.api
|
||||
import glance.tests.functional.db as db_tests
|
||||
from glance.tests import functional
|
||||
import glance.tests.functional.db as db_tests
|
||||
from glance.tests.functional.db import base
|
||||
|
||||
|
||||
|
@ -20,11 +20,11 @@ import uuid
|
||||
|
||||
from oslo.config import cfg
|
||||
|
||||
#NOTE(bcwaldon): importing this to get the default_store option
|
||||
import glance.api.v1.images
|
||||
from glance.common import exception
|
||||
|
||||
import glance.store.location
|
||||
#NOTE(bcwaldon): importing this to get the default_store option
|
||||
import glance.api.v1.images
|
||||
|
||||
CONF = cfg.CONF
|
||||
|
||||
|
@ -17,13 +17,13 @@ import tempfile
|
||||
import fixtures
|
||||
from oslo.config import cfg
|
||||
|
||||
from glance import tests as glance_tests
|
||||
import glance.common.client
|
||||
from glance.common import config
|
||||
import glance.db.sqlalchemy.api
|
||||
import glance.db.sqlalchemy.migration
|
||||
import glance.registry.client.v1.client
|
||||
import glance.store
|
||||
from glance import tests as glance_tests
|
||||
from glance.tests import utils as test_utils
|
||||
|
||||
|
||||
|
@ -22,13 +22,13 @@ import tempfile
|
||||
import fixtures
|
||||
from oslo.config import cfg
|
||||
|
||||
from glance import tests as glance_tests
|
||||
import glance.common.client
|
||||
from glance.common import config
|
||||
import glance.db.sqlalchemy.api
|
||||
import glance.db.sqlalchemy.migration
|
||||
import glance.registry.client.v1.client
|
||||
import glance.store
|
||||
from glance import tests as glance_tests
|
||||
from glance.tests import utils as test_utils
|
||||
|
||||
|
||||
|
@ -15,17 +15,17 @@
|
||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
import json
|
||||
import datetime
|
||||
import json
|
||||
|
||||
import mox
|
||||
from oslo.config import cfg
|
||||
import routes
|
||||
import webob
|
||||
|
||||
from glance.common import exception
|
||||
from glance.common import rpc
|
||||
from glance.common import wsgi
|
||||
from glance.common import exception
|
||||
from glance.tests.unit import base
|
||||
from glance.tests import utils as test_utils
|
||||
|
||||
|
@ -26,8 +26,8 @@ from glance.common import auth
|
||||
from glance.common import exception
|
||||
import glance.domain
|
||||
from glance.openstack.common import timeutils
|
||||
from glance.tests import utils
|
||||
from glance.tests.unit import utils as unittest_utils
|
||||
from glance.tests import utils
|
||||
|
||||
|
||||
TENANT1 = '6838eb7b-6ded-434a-882c-b344c77fe8df'
|
||||
|
@ -22,8 +22,8 @@ from oslo.config import cfg
|
||||
from glance.common import exception
|
||||
from glance import domain
|
||||
from glance.openstack.common import timeutils
|
||||
import glance.tests.utils as test_utils
|
||||
import glance.tests.unit.utils as unittest_utils
|
||||
import glance.tests.utils as test_utils
|
||||
|
||||
|
||||
CONF = cfg.CONF
|
||||
|
@ -24,8 +24,8 @@ import uuid
|
||||
|
||||
import fixtures
|
||||
|
||||
from glance.tests import utils as test_utils
|
||||
from glance.cmd import replicator as glance_replicator
|
||||
from glance.tests import utils as test_utils
|
||||
|
||||
|
||||
IMG_RESPONSE_ACTIVE = {
|
||||
|
@ -20,8 +20,8 @@ import mock
|
||||
from glance.common import exception
|
||||
from glance.common import utils
|
||||
from glance.openstack.common import units
|
||||
import glance.store.rbd as rbd_store
|
||||
from glance.store.location import Location
|
||||
import glance.store.rbd as rbd_store
|
||||
from glance.store.rbd import StoreLocation
|
||||
from glance.tests.unit import base
|
||||
from glance.tests.unit.fake_rados import mock_rados
|
||||
|
@ -17,8 +17,8 @@
|
||||
|
||||
import os
|
||||
import shutil
|
||||
import time
|
||||
import tempfile
|
||||
import time
|
||||
import uuid
|
||||
|
||||
import eventlet
|
||||
|
@ -41,8 +41,8 @@ from glance.openstack.common import timeutils
|
||||
import glance.registry.client.v1.api as registry
|
||||
import glance.store.filesystem
|
||||
from glance.tests.unit import base
|
||||
from glance.tests import utils as test_utils
|
||||
import glance.tests.unit.utils as unit_test_utils
|
||||
from glance.tests import utils as test_utils
|
||||
|
||||
CONF = cfg.CONF
|
||||
|
||||
|
@ -23,15 +23,14 @@ import uuid
|
||||
import mox
|
||||
import testtools
|
||||
|
||||
from glance.common import client as test_client
|
||||
from glance.common import config
|
||||
from glance.common import exception
|
||||
from glance.common import client as test_client
|
||||
from glance import context
|
||||
from glance.db.sqlalchemy import api as db_api
|
||||
from glance.openstack.common import timeutils
|
||||
|
||||
import glance.registry.client.v1.api as rapi
|
||||
from glance.registry.api.v1.images import Controller as rcontroller
|
||||
import glance.registry.client.v1.api as rapi
|
||||
from glance.registry.client.v1.api import client as rclient
|
||||
from glance.tests.unit import base
|
||||
from glance.tests import utils as test_utils
|
||||
|
@ -34,9 +34,9 @@ from glance import context
|
||||
from glance.db.sqlalchemy import api as db_api
|
||||
from glance.openstack.common import timeutils
|
||||
|
||||
from glance.registry.api import v2 as rserver
|
||||
import glance.registry.client.v2.api as rapi
|
||||
from glance.registry.client.v2.api import client as rclient
|
||||
from glance.registry.api import v2 as rserver
|
||||
from glance.tests.unit import base
|
||||
from glance.tests import utils as test_utils
|
||||
|
||||
|
@ -36,13 +36,13 @@ import webob
|
||||
|
||||
from glance.common import config
|
||||
from glance.common import exception
|
||||
from glance.common import property_utils
|
||||
from glance.common import utils
|
||||
from glance.common import wsgi
|
||||
from glance import context
|
||||
from glance.db.sqlalchemy import api as db_api
|
||||
from glance.db.sqlalchemy import models as db_models
|
||||
from glance.openstack.common import timeutils
|
||||
from glance import context
|
||||
from glance.common import property_utils
|
||||
|
||||
CONF = cfg.CONF
|
||||
|
||||
|
@ -19,9 +19,9 @@ import keystoneclient.v2_0.client
|
||||
from oslo.config import cfg
|
||||
|
||||
import glance.context
|
||||
import glance.db.sqlalchemy.api as db_api
|
||||
import glance.openstack.common.log as logging
|
||||
import glance.registry.context
|
||||
import glance.db.sqlalchemy.api as db_api
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
LOG.addHandler(logging.StreamHandler())
|
||||
|
3
tox.ini
3
tox.ini
@ -34,10 +34,9 @@ commands = {posargs}
|
||||
# F821 undefined name 'name'
|
||||
# F841 local variable 'name' assigned but never used
|
||||
# H202 assertRaises Exception too broad
|
||||
# H306 imports not in alphabetical order
|
||||
# H402 one line docstring needs punctuation.
|
||||
# H404 multi line docstring should start with a summary
|
||||
# H703 multiple positional placeholders
|
||||
ignore = E711,E712,F811,F821,F841,H202,H306,H402,H404,H703
|
||||
ignore = E711,E712,F811,F821,F841,H202,H402,H404,H703
|
||||
builtins = _
|
||||
exclude = .venv,.git,.tox,dist,doc,etc,*glance/locale*,*openstack/common*,*lib/python*,*egg,build
|
||||
|
Loading…
x
Reference in New Issue
Block a user