summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbin/heat-api2
-rwxr-xr-xbin/heat-api-cfn2
-rwxr-xr-xbin/heat-api-cloudwatch2
-rwxr-xr-xbin/heat-engine3
-rw-r--r--contrib/nova_flavor/nova_flavor/tests/test_nova_flavor.py2
-rw-r--r--contrib/rackspace/rackspace/clients.py7
-rw-r--r--contrib/rackspace/rackspace/tests/test_cloud_loadbalancer.py3
-rw-r--r--contrib/rackspace/rackspace/tests/test_cloudnetworks.py2
-rwxr-xr-xheat/cloudinit/loguserdata.py3
-rw-r--r--heat/common/heat_keystoneclient.py2
-rw-r--r--heat/common/plugin_loader.py3
-rw-r--r--heat/common/template_format.py2
-rw-r--r--heat/common/urlfetch.py1
-rw-r--r--heat/db/sqlalchemy/api.py2
-rw-r--r--heat/engine/attributes.py3
-rw-r--r--heat/engine/cfn/template.py1
-rw-r--r--heat/engine/clients/__init__.py4
-rw-r--r--heat/engine/clients/client_plugin.py1
-rw-r--r--heat/engine/hot/functions.py1
-rw-r--r--heat/engine/hot/template.py1
-rw-r--r--heat/engine/resource.py3
-rw-r--r--heat/engine/resources/aws/autoscaling_group.py1
-rw-r--r--heat/engine/resources/aws/scaling_policy.py1
-rw-r--r--heat/engine/resources/eip.py2
-rw-r--r--heat/engine/resources/loadbalancer.py2
-rw-r--r--heat/engine/resources/nova_floatingip.py2
-rw-r--r--heat/engine/resources/nova_utils.py4
-rw-r--r--heat/engine/resources/openstack/scaling_policy.py3
-rw-r--r--heat/engine/resources/openstack/wait_condition.py2
-rw-r--r--heat/engine/resources/remote_stack.py1
-rw-r--r--heat/engine/resources/resource_group.py1
-rw-r--r--heat/engine/resources/s3.py1
-rw-r--r--heat/engine/resources/server.py2
-rw-r--r--heat/engine/resources/software_config/software_deployment.py3
-rw-r--r--heat/engine/resources/software_config/structured_config.py1
-rw-r--r--heat/engine/resources/swift.py1
-rw-r--r--heat/engine/resources/swiftsignal.py3
-rw-r--r--heat/engine/rsrc_defn.py2
-rw-r--r--heat/engine/service.py2
-rw-r--r--heat/engine/stack_resource.py2
-rw-r--r--heat/engine/template.py1
-rw-r--r--heat/scaling/template.py1
-rw-r--r--heat/tests/autoscaling/test_heat_scaling_policy.py1
-rw-r--r--heat/tests/autoscaling/test_scaling_policy.py1
-rw-r--r--heat/tests/aws/test_volume.py2
-rw-r--r--heat/tests/aws/test_waitcondition.py2
-rw-r--r--heat/tests/openstack/test_waitcondition.py3
-rw-r--r--heat/tests/test_api_cfn_v1.py2
-rw-r--r--heat/tests/test_api_ec2token.py2
-rw-r--r--heat/tests/test_autoscaling_update_policy.py2
-rw-r--r--heat/tests/test_cinder_client.py3
-rw-r--r--heat/tests/test_clients.py12
-rw-r--r--heat/tests/test_cloud_config.py3
-rw-r--r--heat/tests/test_common_context.py3
-rw-r--r--heat/tests/test_eip.py1
-rw-r--r--heat/tests/test_engine_api_utils.py2
-rw-r--r--heat/tests/test_engine_service.py3
-rw-r--r--heat/tests/test_fault_middleware.py6
-rw-r--r--heat/tests/test_function.py3
-rw-r--r--heat/tests/test_glance_client.py4
-rw-r--r--heat/tests/test_heatclient.py4
-rw-r--r--heat/tests/test_hot.py1
-rw-r--r--heat/tests/test_instance.py2
-rw-r--r--heat/tests/test_instance_group.py2
-rw-r--r--heat/tests/test_loguserdata.py5
-rw-r--r--heat/tests/test_multi_part.py2
-rw-r--r--heat/tests/test_nested_stack.py4
-rw-r--r--heat/tests/test_neutron.py2
-rw-r--r--heat/tests/test_neutron_autoscaling.py2
-rw-r--r--heat/tests/test_neutron_firewall.py2
-rw-r--r--heat/tests/test_neutron_loadbalancer.py6
-rw-r--r--heat/tests/test_neutron_vpnservice.py1
-rw-r--r--heat/tests/test_nova_client.py3
-rw-r--r--heat/tests/test_nova_floatingip.py1
-rw-r--r--heat/tests/test_nova_keypair.py1
-rw-r--r--heat/tests/test_nova_servergroup.py1
-rw-r--r--heat/tests/test_nova_utils.py4
-rw-r--r--heat/tests/test_parameters.py2
-rw-r--r--heat/tests/test_parser.py2
-rw-r--r--heat/tests/test_provider_template.py2
-rw-r--r--heat/tests/test_remote_stack.py4
-rw-r--r--heat/tests/test_resource_group.py3
-rw-r--r--heat/tests/test_rpc_client.py2
-rw-r--r--heat/tests/test_rsrc_defn.py3
-rw-r--r--heat/tests/test_server.py6
-rw-r--r--heat/tests/test_software_deployment.py1
-rw-r--r--heat/tests/test_sqlalchemy_api.py2
-rw-r--r--heat/tests/test_stack_resource.py2
-rw-r--r--heat/tests/test_stack_user.py3
-rw-r--r--heat/tests/test_wsgi.py2
-rw-r--r--heat/tests/v1_1/fakes.py3
-rw-r--r--heat_integrationtests/common/remote_client.py5
-rw-r--r--heat_integrationtests/common/test.py8
-rw-r--r--heat_integrationtests/functional/test_remote_stack.py3
-rw-r--r--heat_integrationtests/functional/test_resource_group.py3
-rw-r--r--heat_integrationtests/functional/test_template_resource.py1
-rw-r--r--heat_integrationtests/scenario/test_volumes.py4
-rw-r--r--tox.ini4
98 files changed, 134 insertions, 117 deletions
diff --git a/bin/heat-api b/bin/heat-api
index 77f11f8c5..871bcf157 100755
--- a/bin/heat-api
+++ b/bin/heat-api
@@ -20,7 +20,6 @@ import eventlet
eventlet.monkey_patch(os=False)
import os
-import six
import sys
# If ../heat/__init__.py exists, add ../ to Python search path, so that
@@ -33,6 +32,7 @@ if os.path.exists(os.path.join(possible_topdir, 'heat', '__init__.py')):
from oslo.config import cfg
from oslo import i18n
+import six
from heat.common import config
from heat.common.i18n import _LI
diff --git a/bin/heat-api-cfn b/bin/heat-api-cfn
index 2d1038bc2..10216f8fb 100755
--- a/bin/heat-api-cfn
+++ b/bin/heat-api-cfn
@@ -22,7 +22,6 @@ import eventlet
eventlet.monkey_patch(os=False)
import os
-import six
import sys
# If ../heat/__init__.py exists, add ../ to Python search path, so that
@@ -35,6 +34,7 @@ if os.path.exists(os.path.join(possible_topdir, 'heat', '__init__.py')):
from oslo.config import cfg
from oslo import i18n
+import six
from heat.common import config
from heat.common.i18n import _LI
diff --git a/bin/heat-api-cloudwatch b/bin/heat-api-cloudwatch
index 0cecfffbd..00df9970b 100755
--- a/bin/heat-api-cloudwatch
+++ b/bin/heat-api-cloudwatch
@@ -22,7 +22,6 @@ import eventlet
eventlet.monkey_patch(os=False)
import os
-import six
import sys
# If ../heat/__init__.py exists, add ../ to Python search path, so that
@@ -35,6 +34,7 @@ if os.path.exists(os.path.join(possible_topdir, 'heat', '__init__.py')):
from oslo.config import cfg
from oslo import i18n
+import six
from heat.common import config
from heat.common.i18n import _LI
diff --git a/bin/heat-engine b/bin/heat-engine
index a25f11aef..47348dbd6 100755
--- a/bin/heat-engine
+++ b/bin/heat-engine
@@ -41,7 +41,6 @@ from heat.common import profiler
from heat.engine import template
from heat.openstack.common import log as logging
from heat.openstack.common import service
-
from heat.rpc import api as rpc_api
i18n.enable_lazy()
@@ -62,7 +61,7 @@ if __name__ == '__main__':
if not mgr or not mgr.names():
sys.exit("ERROR: No template format plugins registered")
- from heat.engine import service as engine
+ from heat.engine import service as engine # noqa
profiler.setup('heat-engine', cfg.CONF.host)
srv = engine.EngineService(cfg.CONF.host, rpc_api.ENGINE_TOPIC)
diff --git a/contrib/nova_flavor/nova_flavor/tests/test_nova_flavor.py b/contrib/nova_flavor/nova_flavor/tests/test_nova_flavor.py
index a14955570..3d412aac6 100644
--- a/contrib/nova_flavor/nova_flavor/tests/test_nova_flavor.py
+++ b/contrib/nova_flavor/nova_flavor/tests/test_nova_flavor.py
@@ -18,9 +18,9 @@ from heat.engine import resource
from heat.engine import template
from heat.tests import common
from heat.tests import utils
+from heat.tests.v1_1 import fakes
from ..resources import nova_flavor # noqa
-from heat.tests.v1_1 import fakes
flavor_template = {
'heat_template_version': '2013-05-23',
diff --git a/contrib/rackspace/rackspace/clients.py b/contrib/rackspace/rackspace/clients.py
index 6c93cc049..38cc20a8b 100644
--- a/contrib/rackspace/rackspace/clients.py
+++ b/contrib/rackspace/rackspace/clients.py
@@ -18,7 +18,10 @@ import random
import time
import urlparse
+from glanceclient import client as gc
from oslo.config import cfg
+from swiftclient import utils as swiftclient_utils
+from troveclient import client as tc
from heat.common import exception
from heat.common.i18n import _LI
@@ -29,12 +32,8 @@ from heat.engine.clients.os import glance
from heat.engine.clients.os import nova
from heat.engine.clients.os import swift
from heat.engine.clients.os import trove
-
from heat.openstack.common import log as logging
-from glanceclient import client as gc
-from swiftclient import utils as swiftclient_utils
-from troveclient import client as tc
LOG = logging.getLogger(__name__)
diff --git a/contrib/rackspace/rackspace/tests/test_cloud_loadbalancer.py b/contrib/rackspace/rackspace/tests/test_cloud_loadbalancer.py
index 002122600..a2f865759 100644
--- a/contrib/rackspace/rackspace/tests/test_cloud_loadbalancer.py
+++ b/contrib/rackspace/rackspace/tests/test_cloud_loadbalancer.py
@@ -14,9 +14,10 @@
import copy
import json
+import uuid
+
import mock
import six
-import uuid
from heat.common import exception
from heat.common import template_format
diff --git a/contrib/rackspace/rackspace/tests/test_cloudnetworks.py b/contrib/rackspace/rackspace/tests/test_cloudnetworks.py
index ada78f67b..1e1324ebd 100644
--- a/contrib/rackspace/rackspace/tests/test_cloudnetworks.py
+++ b/contrib/rackspace/rackspace/tests/test_cloudnetworks.py
@@ -11,10 +11,10 @@
# License for the specific language governing permissions and limitations
# under the License.
-import six
import uuid
import mock
+import six
from heat.common import exception
from heat.common import template_format
diff --git a/heat/cloudinit/loguserdata.py b/heat/cloudinit/loguserdata.py
index 396da8bbc..bf90af461 100755
--- a/heat/cloudinit/loguserdata.py
+++ b/heat/cloudinit/loguserdata.py
@@ -17,10 +17,11 @@ from distutils import version
import errno
import logging
import os
-import pkg_resources
import subprocess
import sys
+import pkg_resources
+
VAR_PATH = '/var/lib/heat-cfntools'
LOG = logging.getLogger('heat-provision')
diff --git a/heat/common/heat_keystoneclient.py b/heat/common/heat_keystoneclient.py
index 2fafd5c94..0ef7205dc 100644
--- a/heat/common/heat_keystoneclient.py
+++ b/heat/common/heat_keystoneclient.py
@@ -16,7 +16,6 @@
import collections
import copy
import json
-from oslo.utils import importutils
import uuid
from keystoneclient.auth.identity import v3 as kc_auth_v3
@@ -24,6 +23,7 @@ import keystoneclient.exceptions as kc_exception
from keystoneclient import session
from keystoneclient.v3 import client as kc_v3
from oslo.config import cfg
+from oslo.utils import importutils
from heat.common import context
from heat.common import exception
diff --git a/heat/common/plugin_loader.py b/heat/common/plugin_loader.py
index 616fcd3f3..1ad3d3832 100644
--- a/heat/common/plugin_loader.py
+++ b/heat/common/plugin_loader.py
@@ -20,10 +20,11 @@ for them before loading them.
"""
import pkgutil
-import six
import sys
import types
+import six
+
from heat.common.i18n import _LE
from heat.openstack.common import log as logging
diff --git a/heat/common/template_format.py b/heat/common/template_format.py
index 3dea95373..28e4e7392 100644
--- a/heat/common/template_format.py
+++ b/heat/common/template_format.py
@@ -14,9 +14,9 @@
import itertools
import json
import re
-import six
from oslo.config import cfg
+import six
import yaml
from heat.common import exception
diff --git a/heat/common/urlfetch.py b/heat/common/urlfetch.py
index d2bba2d96..1f8e45528 100644
--- a/heat/common/urlfetch.py
+++ b/heat/common/urlfetch.py
@@ -16,7 +16,6 @@
from oslo.config import cfg
import requests
from requests import exceptions
-
from six.moves import urllib
from heat.common import exception
diff --git a/heat/db/sqlalchemy/api.py b/heat/db/sqlalchemy/api.py
index efeb07623..9be5a0b87 100644
--- a/heat/db/sqlalchemy/api.py
+++ b/heat/db/sqlalchemy/api.py
@@ -13,13 +13,13 @@
'''Implementation of SQLAlchemy backend.'''
import datetime
-import six
import sys
from oslo.config import cfg
from oslo.db.sqlalchemy import session as db_session
from oslo.db.sqlalchemy import utils
import osprofiler.sqlalchemy
+import six
import sqlalchemy
from sqlalchemy import orm
from sqlalchemy.orm import session as orm_session
diff --git a/heat/engine/attributes.py b/heat/engine/attributes.py
index e76032884..09630a1a6 100644
--- a/heat/engine/attributes.py
+++ b/heat/engine/attributes.py
@@ -12,9 +12,10 @@
# under the License.
import collections
-import six
import warnings
+import six
+
from heat.common.i18n import _
from heat.engine import constraints as constr
from heat.engine import support
diff --git a/heat/engine/cfn/template.py b/heat/engine/cfn/template.py
index 00b2f079d..dfb314732 100644
--- a/heat/engine/cfn/template.py
+++ b/heat/engine/cfn/template.py
@@ -12,6 +12,7 @@
# under the License.
import collections
+
import six
from heat.common.i18n import _
diff --git a/heat/engine/clients/__init__.py b/heat/engine/clients/__init__.py
index 94d48d16e..56203ec18 100644
--- a/heat/engine/clients/__init__.py
+++ b/heat/engine/clients/__init__.py
@@ -11,12 +11,12 @@
# License for the specific language governing permissions and limitations
# under the License.
-import six
+import warnings
from oslo.config import cfg
from oslo.utils import importutils
+import six
from stevedore import extension
-import warnings
from heat.common import exception
from heat.common.i18n import _LE
diff --git a/heat/engine/clients/client_plugin.py b/heat/engine/clients/client_plugin.py
index 031e590fe..75b363643 100644
--- a/heat/engine/clients/client_plugin.py
+++ b/heat/engine/clients/client_plugin.py
@@ -12,6 +12,7 @@
# under the License.
import abc
+
from oslo.config import cfg
import six
diff --git a/heat/engine/hot/functions.py b/heat/engine/hot/functions.py
index 2294c3b07..a2eb6ed9a 100644
--- a/heat/engine/hot/functions.py
+++ b/heat/engine/hot/functions.py
@@ -12,6 +12,7 @@
# under the License.
import collections
+
import six
from heat.common import exception
diff --git a/heat/engine/hot/template.py b/heat/engine/hot/template.py
index 78b7c5f4a..32ebcbd95 100644
--- a/heat/engine/hot/template.py
+++ b/heat/engine/hot/template.py
@@ -11,6 +11,7 @@
# under the License.
import collections
+
import six
from heat.common import exception
diff --git a/heat/engine/resource.py b/heat/engine/resource.py
index 99e19e7b0..4277efd03 100644
--- a/heat/engine/resource.py
+++ b/heat/engine/resource.py
@@ -14,11 +14,12 @@
import base64
import contextlib
import datetime as dt
+import warnings
+
from oslo.config import cfg
from oslo.utils import encodeutils
from oslo.utils import excutils
import six
-import warnings
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/engine/resources/aws/autoscaling_group.py b/heat/engine/resources/aws/autoscaling_group.py
index df7c94ff0..d1d54d226 100644
--- a/heat/engine/resources/aws/autoscaling_group.py
+++ b/heat/engine/resources/aws/autoscaling_group.py
@@ -12,6 +12,7 @@
# under the License.
import math
+
from oslo.utils import excutils
import six
diff --git a/heat/engine/resources/aws/scaling_policy.py b/heat/engine/resources/aws/scaling_policy.py
index 5d0477b76..ced8727c3 100644
--- a/heat/engine/resources/aws/scaling_policy.py
+++ b/heat/engine/resources/aws/scaling_policy.py
@@ -15,7 +15,6 @@ import six
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
-
from heat.engine import attributes
from heat.engine import constraints
from heat.engine import properties
diff --git a/heat/engine/resources/eip.py b/heat/engine/resources/eip.py
index 95bd291c5..2ff9ca696 100644
--- a/heat/engine/resources/eip.py
+++ b/heat/engine/resources/eip.py
@@ -10,9 +10,9 @@
# 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 six
from oslo.utils import excutils
+import six
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/engine/resources/loadbalancer.py b/heat/engine/resources/loadbalancer.py
index 4e4aa62ba..16481af21 100644
--- a/heat/engine/resources/loadbalancer.py
+++ b/heat/engine/resources/loadbalancer.py
@@ -11,9 +11,9 @@
# License for the specific language governing permissions and limitations
# under the License.
import os
-import six
from oslo.config import cfg
+import six
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/engine/resources/nova_floatingip.py b/heat/engine/resources/nova_floatingip.py
index 8ab82bdc0..b4563dc07 100644
--- a/heat/engine/resources/nova_floatingip.py
+++ b/heat/engine/resources/nova_floatingip.py
@@ -10,9 +10,9 @@
# 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 six
from oslo.utils import excutils
+import six
from heat.common.i18n import _
from heat.common.i18n import _LE
diff --git a/heat/engine/resources/nova_utils.py b/heat/engine/resources/nova_utils.py
index 5af2d4347..d4f65a77e 100644
--- a/heat/engine/resources/nova_utils.py
+++ b/heat/engine/resources/nova_utils.py
@@ -16,15 +16,15 @@ import email
from email.mime import multipart
from email.mime import text
import json
-from novaclient import exceptions as nova_exceptions
import os
import pkgutil
import string
+import warnings
+from novaclient import exceptions as nova_exceptions
from oslo.config import cfg
import six
from six.moves.urllib import parse as urlparse
-import warnings
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/engine/resources/openstack/scaling_policy.py b/heat/engine/resources/openstack/scaling_policy.py
index b2e0de027..02abe9a53 100644
--- a/heat/engine/resources/openstack/scaling_policy.py
+++ b/heat/engine/resources/openstack/scaling_policy.py
@@ -20,9 +20,8 @@ from heat.engine import constraints
from heat.engine import properties
from heat.engine import resource
from heat.engine import signal_responder
-from heat.scaling import cooldown
-
from heat.openstack.common import log as logging
+from heat.scaling import cooldown
LOG = logging.getLogger(__name__)
diff --git a/heat/engine/resources/openstack/wait_condition.py b/heat/engine/resources/openstack/wait_condition.py
index 814635516..759c249e5 100644
--- a/heat/engine/resources/openstack/wait_condition.py
+++ b/heat/engine/resources/openstack/wait_condition.py
@@ -12,6 +12,7 @@
# under the License.
import json
+
import six
from heat.common.i18n import _
@@ -23,7 +24,6 @@ from heat.engine import resource
from heat.engine.resources import wait_condition as wc_base
from heat.engine import scheduler
from heat.engine import support
-
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)
diff --git a/heat/engine/resources/remote_stack.py b/heat/engine/resources/remote_stack.py
index 238db5c76..6a4993799 100644
--- a/heat/engine/resources/remote_stack.py
+++ b/heat/engine/resources/remote_stack.py
@@ -23,7 +23,6 @@ from heat.engine import environment
from heat.engine import function
from heat.engine import properties
from heat.engine import resource
-
from heat.openstack.common import log as logging
LOG = logging.getLogger(__name__)
diff --git a/heat/engine/resources/resource_group.py b/heat/engine/resources/resource_group.py
index 856853639..b7cd711d1 100644
--- a/heat/engine/resources/resource_group.py
+++ b/heat/engine/resources/resource_group.py
@@ -13,6 +13,7 @@
import collections
import copy
+
import six
from heat.common import exception
diff --git a/heat/engine/resources/s3.py b/heat/engine/resources/s3.py
index ce6a38ca1..53026e42b 100644
--- a/heat/engine/resources/s3.py
+++ b/heat/engine/resources/s3.py
@@ -11,7 +11,6 @@
# License for the specific language governing permissions and limitations
# under the License.
import six
-
from six.moves.urllib import parse as urlparse
from heat.common import exception
diff --git a/heat/engine/resources/server.py b/heat/engine/resources/server.py
index 04721ce11..051ec162a 100644
--- a/heat/engine/resources/server.py
+++ b/heat/engine/resources/server.py
@@ -12,12 +12,12 @@
# under the License.
import copy
-import six
import uuid
from oslo.config import cfg
from oslo.serialization import jsonutils
from oslo.utils import uuidutils
+import six
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/engine/resources/software_config/software_deployment.py b/heat/engine/resources/software_config/software_deployment.py
index d349c288a..2e735da98 100644
--- a/heat/engine/resources/software_config/software_deployment.py
+++ b/heat/engine/resources/software_config/software_deployment.py
@@ -12,9 +12,10 @@
# under the License.
import copy
-import six
import uuid
+import six
+
from heat.common import exception
from heat.common.i18n import _
from heat.engine import attributes
diff --git a/heat/engine/resources/software_config/structured_config.py b/heat/engine/resources/software_config/structured_config.py
index 3aa687d0e..4b0c588a3 100644
--- a/heat/engine/resources/software_config/structured_config.py
+++ b/heat/engine/resources/software_config/structured_config.py
@@ -13,6 +13,7 @@
import collections
import functools
+
import six
from heat.common import exception
diff --git a/heat/engine/resources/swift.py b/heat/engine/resources/swift.py
index 9e35c8316..df0a3f0cb 100644
--- a/heat/engine/resources/swift.py
+++ b/heat/engine/resources/swift.py
@@ -11,7 +11,6 @@
# License for the specific language governing permissions and limitations
# under the License.
import six
-
from six.moves.urllib import parse as urlparse
from heat.common import exception
diff --git a/heat/engine/resources/swiftsignal.py b/heat/engine/resources/swiftsignal.py
index 849887867..45aca0601 100644
--- a/heat/engine/resources/swiftsignal.py
+++ b/heat/engine/resources/swiftsignal.py
@@ -12,9 +12,10 @@
# under the License.
import json
-import six
import urlparse
+import six
+
from heat.common import exception
from heat.common.i18n import _
from heat.common.i18n import _LI
diff --git a/heat/engine/rsrc_defn.py b/heat/engine/rsrc_defn.py
index 502bbb0d2..6ce36ed38 100644
--- a/heat/engine/rsrc_defn.py
+++ b/heat/engine/rsrc_defn.py
@@ -14,10 +14,10 @@ import collections
import copy
import itertools
import operator
+
import six
from heat.common import exception
-
from heat.engine import function
from heat.engine import properties
diff --git a/heat/engine/service.py b/heat/engine/service.py
index 9f63bceab..a0109f362 100644
--- a/heat/engine/service.py
+++ b/heat/engine/service.py
@@ -15,6 +15,7 @@ import collections
import functools
import json
import os
+import warnings
import eventlet
from oslo.config import cfg
@@ -24,7 +25,6 @@ from oslo.utils import uuidutils
from osprofiler import profiler
import requests
import six
-import warnings
import webob
from heat.common import context
diff --git a/heat/engine/stack_resource.py b/heat/engine/stack_resource.py
index 65bac88a1..579366b19 100644
--- a/heat/engine/stack_resource.py
+++ b/heat/engine/stack_resource.py
@@ -12,10 +12,10 @@
# under the License.
import hashlib
-import six
from oslo.config import cfg
from oslo.serialization import jsonutils
+import six
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/engine/template.py b/heat/engine/template.py
index 61d5fdb7f..9357fbb59 100644
--- a/heat/engine/template.py
+++ b/heat/engine/template.py
@@ -15,6 +15,7 @@ import abc
import collections
import copy
import functools
+
import six
from stevedore import extension
diff --git a/heat/scaling/template.py b/heat/scaling/template.py
index 827becec0..c20c2d871 100644
--- a/heat/scaling/template.py
+++ b/heat/scaling/template.py
@@ -12,7 +12,6 @@
# under the License.
from heat.common import short_id
-
from heat.engine import template
diff --git a/heat/tests/autoscaling/test_heat_scaling_policy.py b/heat/tests/autoscaling/test_heat_scaling_policy.py
index 09624b3da..1113c2f3c 100644
--- a/heat/tests/autoscaling/test_heat_scaling_policy.py
+++ b/heat/tests/autoscaling/test_heat_scaling_policy.py
@@ -12,6 +12,7 @@
# under the License.
import datetime
+
import mock
from oslo.config import cfg
from oslo.utils import timeutils
diff --git a/heat/tests/autoscaling/test_scaling_policy.py b/heat/tests/autoscaling/test_scaling_policy.py
index 29e45a080..e24247528 100644
--- a/heat/tests/autoscaling/test_scaling_policy.py
+++ b/heat/tests/autoscaling/test_scaling_policy.py
@@ -12,6 +12,7 @@
# under the License.
import datetime
+
import mock
from oslo.config import cfg
from oslo.utils import timeutils
diff --git a/heat/tests/aws/test_volume.py b/heat/tests/aws/test_volume.py
index dc0556c6c..ab86c08f4 100644
--- a/heat/tests/aws/test_volume.py
+++ b/heat/tests/aws/test_volume.py
@@ -12,9 +12,9 @@
# under the License.
import copy
-import mock
from cinderclient import exceptions as cinder_exp
+import mock
import mox
from oslo.config import cfg
import six
diff --git a/heat/tests/aws/test_waitcondition.py b/heat/tests/aws/test_waitcondition.py
index 3a0a0a567..79942bb98 100644
--- a/heat/tests/aws/test_waitcondition.py
+++ b/heat/tests/aws/test_waitcondition.py
@@ -14,12 +14,12 @@
import copy
import datetime
import json
-import six
import time
import uuid
import mox
from oslo.config import cfg
+import six
from heat.common import identifier
from heat.common import template_format
diff --git a/heat/tests/openstack/test_waitcondition.py b/heat/tests/openstack/test_waitcondition.py
index f85ea5db3..fb69ee505 100644
--- a/heat/tests/openstack/test_waitcondition.py
+++ b/heat/tests/openstack/test_waitcondition.py
@@ -11,10 +11,11 @@
# License for the specific language governing permissions and limitations
# under the License.
-import six
import time
import uuid
+import six
+
from heat.common import identifier
from heat.common import template_format
from heat.db import api as db_api
diff --git a/heat/tests/test_api_cfn_v1.py b/heat/tests/test_api_cfn_v1.py
index 18c05be81..19566862f 100644
--- a/heat/tests/test_api_cfn_v1.py
+++ b/heat/tests/test_api_cfn_v1.py
@@ -13,10 +13,10 @@
import json
import os
-import six
import mock
from oslo.config import cfg
+import six
from heat.api.aws import exception
import heat.api.cfn.v1.stacks as stacks
diff --git a/heat/tests/test_api_ec2token.py b/heat/tests/test_api_ec2token.py
index e679b129b..aaec80e9c 100644
--- a/heat/tests/test_api_ec2token.py
+++ b/heat/tests/test_api_ec2token.py
@@ -13,11 +13,11 @@
import json
-import six
from oslo.config import cfg
from oslo.utils import importutils
import requests
+import six
from heat.api.aws import ec2token
from heat.api.aws import exception
diff --git a/heat/tests/test_autoscaling_update_policy.py b/heat/tests/test_autoscaling_update_policy.py
index ccb57bff1..8ca86fc17 100644
--- a/heat/tests/test_autoscaling_update_policy.py
+++ b/heat/tests/test_autoscaling_update_policy.py
@@ -13,10 +13,10 @@
import copy
import json
-import six
import mox
from oslo.config import cfg
+import six
from testtools import matchers
from heat.common import exception
diff --git a/heat/tests/test_cinder_client.py b/heat/tests/test_cinder_client.py
index d4a28d41b..91de76ca3 100644
--- a/heat/tests/test_cinder_client.py
+++ b/heat/tests/test_cinder_client.py
@@ -12,9 +12,10 @@
# under the License.
"""Tests for :module:'heat.engine.clients.os.cinder'."""
-import mock
import uuid
+import mock
+
from heat.common import exception
from heat.engine.clients.os import cinder
from heat.tests import common
diff --git a/heat/tests/test_clients.py b/heat/tests/test_clients.py
index 95c7fd4d1..b60aab081 100644
--- a/heat/tests/test_clients.py
+++ b/heat/tests/test_clients.py
@@ -11,23 +11,21 @@
# License for the specific language governing permissions and limitations
# under the License.
-import six
-
from ceilometerclient import exc as ceil_exc
from ceilometerclient.openstack.common.apiclient import exceptions as c_a_exc
from cinderclient import exceptions as cinder_exc
from glanceclient import exc as glance_exc
+from heatclient import client as heatclient
from heatclient import exc as heat_exc
from keystoneclient import exceptions as keystone_exc
+import mock
from neutronclient.common import exceptions as neutron_exc
+from oslo.config import cfg
from saharaclient.api import base as sahara_base
+import six
from swiftclient import exceptions as swift_exc
-from troveclient import client as troveclient
-
-from heatclient import client as heatclient
-import mock
-from oslo.config import cfg
from testtools import testcase
+from troveclient import client as troveclient
from heat.common import exception
from heat.engine import clients
diff --git a/heat/tests/test_cloud_config.py b/heat/tests/test_cloud_config.py
index a7b2b595a..f059d7115 100644
--- a/heat/tests/test_cloud_config.py
+++ b/heat/tests/test_cloud_config.py
@@ -11,9 +11,10 @@
# License for the specific language governing permissions and limitations
# under the License.
-import mock
import uuid
+import mock
+
from heat.engine import parser
from heat.engine.resources.software_config import cloud_config as cc
from heat.engine import template
diff --git a/heat/tests/test_common_context.py b/heat/tests/test_common_context.py
index ef1042e74..6a578b812 100644
--- a/heat/tests/test_common_context.py
+++ b/heat/tests/test_common_context.py
@@ -11,8 +11,9 @@
# License for the specific language governing permissions and limitations
# under the License.
-import mock
import os
+
+import mock
from oslo.config import cfg
from oslo_middleware import request_id
import webob
diff --git a/heat/tests/test_eip.py b/heat/tests/test_eip.py
index e681567bf..7d3791a82 100644
--- a/heat/tests/test_eip.py
+++ b/heat/tests/test_eip.py
@@ -12,6 +12,7 @@
# under the License.
import copy
+
import mox
from neutronclient.v2_0 import client as neutronclient
from novaclient import exceptions as nova_exceptions
diff --git a/heat/tests/test_engine_api_utils.py b/heat/tests/test_engine_api_utils.py
index 01e740fae..73c831c3a 100644
--- a/heat/tests/test_engine_api_utils.py
+++ b/heat/tests/test_engine_api_utils.py
@@ -12,9 +12,9 @@
# under the License.
import datetime as dt
+import json
import uuid
-import json
import mock
import six
diff --git a/heat/tests/test_engine_service.py b/heat/tests/test_engine_service.py
index 8c101f53b..9772c174c 100644
--- a/heat/tests/test_engine_service.py
+++ b/heat/tests/test_engine_service.py
@@ -11,13 +11,12 @@
# License for the specific language governing permissions and limitations
# under the License.
-
-import eventlet
import functools
import json
import sys
import uuid
+import eventlet
from eventlet import event as grevent
import mock
import mox
diff --git a/heat/tests/test_fault_middleware.py b/heat/tests/test_fault_middleware.py
index 2c0f84c69..16be4c864 100644
--- a/heat/tests/test_fault_middleware.py
+++ b/heat/tests/test_fault_middleware.py
@@ -12,12 +12,12 @@
# under the License.
import inspect
-from oslo.config import cfg
import re
-import six
-import webob
+from oslo.config import cfg
from oslo.messaging._drivers import common as rpc_common
+import six
+import webob
import heat.api.middleware.fault as fault
from heat.common import exception as heat_exc
diff --git a/heat/tests/test_function.py b/heat/tests/test_function.py
index 58ef0e727..3f3fa382c 100644
--- a/heat/tests/test_function.py
+++ b/heat/tests/test_function.py
@@ -12,9 +12,10 @@
# under the License.
import copy
-import six
import uuid
+import six
+
from heat.common import exception
from heat.common.i18n import _
from heat.engine.cfn import functions
diff --git a/heat/tests/test_glance_client.py b/heat/tests/test_glance_client.py
index d7f73f380..a4c34074c 100644
--- a/heat/tests/test_glance_client.py
+++ b/heat/tests/test_glance_client.py
@@ -11,11 +11,11 @@
# License for the specific language governing permissions and limitations
# under the License.
-import mock
-import six
import uuid
from glanceclient import exc as glance_exceptions
+import mock
+import six
from heat.common import exception
from heat.engine.clients.os import glance
diff --git a/heat/tests/test_heatclient.py b/heat/tests/test_heatclient.py
index 2315860b3..5976fb36f 100644
--- a/heat/tests/test_heatclient.py
+++ b/heat/tests/test_heatclient.py
@@ -12,8 +12,6 @@
# under the License.
import json
-import mox
-import six
import uuid
from keystoneclient.auth.identity import v3 as ks_auth_v3
@@ -21,7 +19,9 @@ import keystoneclient.exceptions as kc_exception
from keystoneclient import session as ks_session
from keystoneclient.v3 import client as kc_v3
from keystoneclient.v3 import domains as kc_v3_domains
+import mox
from oslo.config import cfg
+import six
from heat.common import exception
from heat.common import heat_keystoneclient
diff --git a/heat/tests/test_hot.py b/heat/tests/test_hot.py
index 1b8f49011..e7534ff0d 100644
--- a/heat/tests/test_hot.py
+++ b/heat/tests/test_hot.py
@@ -12,6 +12,7 @@
# under the License.
import copy
+
import six
from heat.common import exception
diff --git a/heat/tests/test_instance.py b/heat/tests/test_instance.py
index 9702ab662..0a0bc822c 100644
--- a/heat/tests/test_instance.py
+++ b/heat/tests/test_instance.py
@@ -12,13 +12,13 @@
# under the License.
import copy
-import six
import uuid
from glanceclient import exc as glance_exceptions
import mock
import mox
from neutronclient.v2_0 import client as neutronclient
+import six
from heat.common import exception
from heat.common import template_format
diff --git a/heat/tests/test_instance_group.py b/heat/tests/test_instance_group.py
index 4d02443da..85c590326 100644
--- a/heat/tests/test_instance_group.py
+++ b/heat/tests/test_instance_group.py
@@ -12,9 +12,9 @@
# under the License.
import copy
-import six
import mock
+import six
from heat.common import exception
from heat.common import grouputils
diff --git a/heat/tests/test_loguserdata.py b/heat/tests/test_loguserdata.py
index fbb569d92..a61313c16 100644
--- a/heat/tests/test_loguserdata.py
+++ b/heat/tests/test_loguserdata.py
@@ -12,11 +12,12 @@
# under the License.
import errno
-import mox
import os
-import pkg_resources
import subprocess
+import mox
+import pkg_resources
+
from heat.cloudinit import loguserdata
from heat.tests import common
diff --git a/heat/tests/test_multi_part.py b/heat/tests/test_multi_part.py
index 1d193384f..5a736582b 100644
--- a/heat/tests/test_multi_part.py
+++ b/heat/tests/test_multi_part.py
@@ -12,9 +12,9 @@
# under the License.
import email
+import uuid
import mock
-import uuid
from heat.common import exception as exc
from heat.engine import parser
diff --git a/heat/tests/test_nested_stack.py b/heat/tests/test_nested_stack.py
index c6bee8b4d..0dd3ec0c1 100644
--- a/heat/tests/test_nested_stack.py
+++ b/heat/tests/test_nested_stack.py
@@ -14,12 +14,12 @@
import copy
import json
-import six
-import yaml
import mock
from oslo.config import cfg
from requests import exceptions
+import six
+import yaml
from heat.common import exception
from heat.common import template_format
diff --git a/heat/tests/test_neutron.py b/heat/tests/test_neutron.py
index a23ecccc4..ac3e744a1 100644
--- a/heat/tests/test_neutron.py
+++ b/heat/tests/test_neutron.py
@@ -12,13 +12,13 @@
# under the License.
import copy
-import six
import mock
import mox
from neutronclient.common import exceptions as qe
from neutronclient.neutron import v2_0 as neutronV20
from neutronclient.v2_0 import client as neutronclient
+import six
from heat.common import exception
from heat.common import template_format
diff --git a/heat/tests/test_neutron_autoscaling.py b/heat/tests/test_neutron_autoscaling.py
index af5f8e653..e2c83ba11 100644
--- a/heat/tests/test_neutron_autoscaling.py
+++ b/heat/tests/test_neutron_autoscaling.py
@@ -12,10 +12,10 @@
# under the License.
import copy
-from neutronclient.v2_0 import client as neutronclient
import uuid
import mox
+from neutronclient.v2_0 import client as neutronclient
from oslo.config import cfg
from heat.common import template_format
diff --git a/heat/tests/test_neutron_firewall.py b/heat/tests/test_neutron_firewall.py
index 393b32ee6..6eecb64c7 100644
--- a/heat/tests/test_neutron_firewall.py
+++ b/heat/tests/test_neutron_firewall.py
@@ -12,10 +12,10 @@
# under the License.
import copy
-import six
from neutronclient.common import exceptions
from neutronclient.v2_0 import client as neutronclient
+import six
from heat.common import exception
from heat.common import template_format
diff --git a/heat/tests/test_neutron_loadbalancer.py b/heat/tests/test_neutron_loadbalancer.py
index b6bb657ed..2ea1fb744 100644
--- a/heat/tests/test_neutron_loadbalancer.py
+++ b/heat/tests/test_neutron_loadbalancer.py
@@ -12,13 +12,13 @@
# under the License.
import copy
-import mox
-from oslo.config import cfg
-import six
+import mox
from neutronclient.common import exceptions
from neutronclient.neutron import v2_0 as neutronV20
from neutronclient.v2_0 import client as neutronclient
+from oslo.config import cfg
+import six
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/tests/test_neutron_vpnservice.py b/heat/tests/test_neutron_vpnservice.py
index 2f54ce2f9..1f527c90d 100644
--- a/heat/tests/test_neutron_vpnservice.py
+++ b/heat/tests/test_neutron_vpnservice.py
@@ -12,6 +12,7 @@
# under the License.
import copy
+
import mox
from neutronclient.common import exceptions
from neutronclient.neutron import v2_0 as neutronV20
diff --git a/heat/tests/test_nova_client.py b/heat/tests/test_nova_client.py
index e237ad000..8dfab6545 100644
--- a/heat/tests/test_nova_client.py
+++ b/heat/tests/test_nova_client.py
@@ -13,11 +13,12 @@
"""Tests for :module:'heat.engine.resources.nova_utls'."""
import collections
+import uuid
+
import mock
from novaclient import exceptions as nova_exceptions
from oslo.config import cfg
import six
-import uuid
from heat.common import exception
from heat.engine.clients.os import nova
diff --git a/heat/tests/test_nova_floatingip.py b/heat/tests/test_nova_floatingip.py
index 62d8404e4..9451c9f45 100644
--- a/heat/tests/test_nova_floatingip.py
+++ b/heat/tests/test_nova_floatingip.py
@@ -12,6 +12,7 @@
# under the License.
import copy
+
import mock
import six
diff --git a/heat/tests/test_nova_keypair.py b/heat/tests/test_nova_keypair.py
index ad3893f98..18338b17e 100644
--- a/heat/tests/test_nova_keypair.py
+++ b/heat/tests/test_nova_keypair.py
@@ -12,6 +12,7 @@
# under the License.
import copy
+
import mock
import six
diff --git a/heat/tests/test_nova_servergroup.py b/heat/tests/test_nova_servergroup.py
index 212b8550d..4269f3a7e 100644
--- a/heat/tests/test_nova_servergroup.py
+++ b/heat/tests/test_nova_servergroup.py
@@ -12,6 +12,7 @@
# under the License.
import json
+
import mock
from heat.common import template_format
diff --git a/heat/tests/test_nova_utils.py b/heat/tests/test_nova_utils.py
index c2567be1e..9d9706dfe 100644
--- a/heat/tests/test_nova_utils.py
+++ b/heat/tests/test_nova_utils.py
@@ -13,11 +13,11 @@
"""Tests for :module:'heat.engine.resources.nova_utls'."""
-import mock
-import six
import uuid
+import mock
from novaclient import exceptions as nova_exceptions
+import six
from heat.common import exception
from heat.engine.resources import nova_utils
diff --git a/heat/tests/test_parameters.py b/heat/tests/test_parameters.py
index 79dbd2df7..1fae69dce 100644
--- a/heat/tests/test_parameters.py
+++ b/heat/tests/test_parameters.py
@@ -12,8 +12,8 @@
# under the License.
import json
-import six
+import six
import testtools
from heat.common import exception
diff --git a/heat/tests/test_parser.py b/heat/tests/test_parser.py
index 099831bdf..ccdbe8233 100644
--- a/heat/tests/test_parser.py
+++ b/heat/tests/test_parser.py
@@ -15,13 +15,13 @@ import collections
import copy
import json
import time
+import warnings
from keystoneclient import exceptions as kc_exceptions
import mock
import mox
from oslo.config import cfg
import six
-import warnings
from heat.common import context
from heat.common import exception
diff --git a/heat/tests/test_provider_template.py b/heat/tests/test_provider_template.py
index 697c89ed9..5910c2039 100644
--- a/heat/tests/test_provider_template.py
+++ b/heat/tests/test_provider_template.py
@@ -13,10 +13,10 @@
import json
import os
-import six
import uuid
import mock
+import six
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/tests/test_remote_stack.py b/heat/tests/test_remote_stack.py
index bdb768617..5746f0bde 100644
--- a/heat/tests/test_remote_stack.py
+++ b/heat/tests/test_remote_stack.py
@@ -12,12 +12,12 @@
# under the License.
import copy
-import mock
-import six
from heatclient import exc
from heatclient.v1 import stacks
+import mock
from oslo.config import cfg
+import six
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/tests/test_resource_group.py b/heat/tests/test_resource_group.py
index c79d14d0e..6b329670a 100644
--- a/heat/tests/test_resource_group.py
+++ b/heat/tests/test_resource_group.py
@@ -12,9 +12,10 @@
# under the License.
import copy
+import uuid
+
import mock
import six
-import uuid
from heat.common import exception
from heat.engine import properties
diff --git a/heat/tests/test_rpc_client.py b/heat/tests/test_rpc_client.py
index 75e94d8b2..501c088b8 100644
--- a/heat/tests/test_rpc_client.py
+++ b/heat/tests/test_rpc_client.py
@@ -17,8 +17,8 @@
Unit Tests for heat.rpc.client
"""
-
import copy
+
import mock
from oslo.messaging._drivers import common as rpc_common
import stubout
diff --git a/heat/tests/test_rsrc_defn.py b/heat/tests/test_rsrc_defn.py
index fce17b730..8de9204f4 100644
--- a/heat/tests/test_rsrc_defn.py
+++ b/heat/tests/test_rsrc_defn.py
@@ -13,13 +13,12 @@
import six
-from heat.tests import common
-
from heat.common import exception
from heat.engine.cfn import functions as cfn_funcs
from heat.engine.hot import functions as hot_funcs
from heat.engine import properties
from heat.engine import rsrc_defn
+from heat.tests import common
class ResourceDefinitionTest(common.HeatTestCase):
diff --git a/heat/tests/test_server.py b/heat/tests/test_server.py
index 3da984a2b..148be18e3 100644
--- a/heat/tests/test_server.py
+++ b/heat/tests/test_server.py
@@ -13,13 +13,13 @@
import collections
import copy
-from oslo.utils import uuidutils
-import six
-from six.moves.urllib import parse as urlparse
import mock
import mox
from novaclient import exceptions as nova_exceptions
+from oslo.utils import uuidutils
+import six
+from six.moves.urllib import parse as urlparse
from heat.common import exception
from heat.common.i18n import _
diff --git a/heat/tests/test_software_deployment.py b/heat/tests/test_software_deployment.py
index 5268e1e5d..21e9feb24 100644
--- a/heat/tests/test_software_deployment.py
+++ b/heat/tests/test_software_deployment.py
@@ -12,6 +12,7 @@
# under the License.
import copy
+
import mock
import six
diff --git a/heat/tests/test_sqlalchemy_api.py b/heat/tests/test_sqlalchemy_api.py
index 028d800ac..b42c846fc 100644
--- a/heat/tests/test_sqlalchemy_api.py
+++ b/heat/tests/test_sqlalchemy_api.py
@@ -13,12 +13,12 @@
import datetime
import json
-import six
import uuid
import mock
import mox
from oslo.utils import timeutils
+import six
from heat.common import context
from heat.common import exception
diff --git a/heat/tests/test_stack_resource.py b/heat/tests/test_stack_resource.py
index ff0be1a3f..a1a04677c 100644
--- a/heat/tests/test_stack_resource.py
+++ b/heat/tests/test_stack_resource.py
@@ -11,10 +11,10 @@
# License for the specific language governing permissions and limitations
# under the License.
-import six
import uuid
import mock
+import six
from heat.common import exception
from heat.common import template_format
diff --git a/heat/tests/test_stack_user.py b/heat/tests/test_stack_user.py
index 29b580e95..95329c746 100644
--- a/heat/tests/test_stack_user.py
+++ b/heat/tests/test_stack_user.py
@@ -11,9 +11,8 @@
# License for the specific language governing permissions and limitations
# under the License.
-import six
-
from keystoneclient import exceptions as kc_exceptions
+import six
from heat.common import exception
from heat.common import short_id
diff --git a/heat/tests/test_wsgi.py b/heat/tests/test_wsgi.py
index 00a1dcbb5..44c4f865b 100644
--- a/heat/tests/test_wsgi.py
+++ b/heat/tests/test_wsgi.py
@@ -16,9 +16,9 @@
import json
-import six
from oslo.config import cfg
+import six
import stubout
import webob
diff --git a/heat/tests/v1_1/fakes.py b/heat/tests/v1_1/fakes.py
index 94d7a7118..85379476d 100644
--- a/heat/tests/v1_1/fakes.py
+++ b/heat/tests/v1_1/fakes.py
@@ -15,11 +15,10 @@
# limitations under the License.
import mock
-import requests
-
from novaclient import client as base_client
from novaclient import exceptions as nova_exceptions
from novaclient.v1_1 import client
+import requests
from six.moves.urllib import parse as urlparse
from heat.tests import fakes
diff --git a/heat_integrationtests/common/remote_client.py b/heat_integrationtests/common/remote_client.py
index 3b48545fa..5365cebcd 100644
--- a/heat_integrationtests/common/remote_client.py
+++ b/heat_integrationtests/common/remote_client.py
@@ -12,13 +12,14 @@
import cStringIO
import logging
-import paramiko
import re
import select
-import six
import socket
import time
+import paramiko
+import six
+
from heat_integrationtests.common import exceptions
LOG = logging.getLogger(__name__)
diff --git a/heat_integrationtests/common/test.py b/heat_integrationtests/common/test.py
index 57083fd74..4c9656737 100644
--- a/heat_integrationtests/common/test.py
+++ b/heat_integrationtests/common/test.py
@@ -10,19 +10,19 @@
# License for the specific language governing permissions and limitations
# under the License.
-import fixtures
import logging
import os
import random
import re
-import six
import subprocess
-import testscenarios
-import testtools
import time
+import fixtures
from heatclient import exc as heat_exceptions
from oslo.utils import timeutils
+import six
+import testscenarios
+import testtools
from heat_integrationtests.common import clients
from heat_integrationtests.common import config
diff --git a/heat_integrationtests/functional/test_remote_stack.py b/heat_integrationtests/functional/test_remote_stack.py
index d9eec79b3..1b6f96189 100644
--- a/heat_integrationtests/functional/test_remote_stack.py
+++ b/heat_integrationtests/functional/test_remote_stack.py
@@ -11,10 +11,11 @@
# under the License.
import logging
+
+from heatclient import exc
import six
from heat_integrationtests.common import test
-from heatclient import exc
LOG = logging.getLogger(__name__)
diff --git a/heat_integrationtests/functional/test_resource_group.py b/heat_integrationtests/functional/test_resource_group.py
index 8ccddd88b..6c68a192c 100644
--- a/heat_integrationtests/functional/test_resource_group.py
+++ b/heat_integrationtests/functional/test_resource_group.py
@@ -10,9 +10,8 @@
# License for the specific language governing permissions and limitations
# under the License.
-import six
-
from heatclient import exc
+import six
from heat_integrationtests.common import test
diff --git a/heat_integrationtests/functional/test_template_resource.py b/heat_integrationtests/functional/test_template_resource.py
index 828ff7486..6b3fabb24 100644
--- a/heat_integrationtests/functional/test_template_resource.py
+++ b/heat_integrationtests/functional/test_template_resource.py
@@ -12,6 +12,7 @@
import json
import logging
+
import yaml
from heat_integrationtests.common import test
diff --git a/heat_integrationtests/scenario/test_volumes.py b/heat_integrationtests/scenario/test_volumes.py
index fe9ec0306..841a0910b 100644
--- a/heat_integrationtests/scenario/test_volumes.py
+++ b/heat_integrationtests/scenario/test_volumes.py
@@ -11,10 +11,10 @@
# under the License.
import logging
-import six
-from testtools import testcase
from cinderclient import exceptions as cinder_exceptions
+import six
+from testtools import testcase
from heat_integrationtests.common import exceptions
from heat_integrationtests.common import test
diff --git a/tox.ini b/tox.ini
index a9a467190..08687b6be 100644
--- a/tox.ini
+++ b/tox.ini
@@ -52,13 +52,11 @@ commands = python setup.py build_sphinx
commands = oslo-config-generator --config-file=config-generator.conf
[flake8]
-# H305 imports not grouped correctly
-# H307 like imports should be grouped togethe
# H404 multi line docstring should start with a summary
# H405 multi line docstring summary not separated with an empty line
# H803 no full stop at the end of the commit message
# H904 Wrap long lines in parentheses instead of a backslash
-ignore = H305,H307,H404,H405,H803,H904
+ignore = H404,H405,H803,H904
show-source = true
exclude=.venv,.git,.tox,dist,*openstack/common*,*lib/python*,*egg,tools,build
max-complexity=20