diff options
author | Sam Betts <sam@code-smash.net> | 2015-05-28 16:54:36 +0100 |
---|---|---|
committer | Sam Betts <sam@code-smash.net> | 2015-06-04 12:56:51 +0100 |
commit | 8c07c4fda3e6a86a40aa00759652b99acbd73331 (patch) | |
tree | 7b68cc4850f42b8ce290a260ab22cc603b8010ee /ironic/common/hash_ring.py | |
parent | 83746b90092a813b82d4e0135c4e6a2f8a5bd52c (diff) | |
download | ironic-8c07c4fda3e6a86a40aa00759652b99acbd73331.tar.gz |
Enforce flake8 E123/6/7/8 in ironic
This patch enforces the rules E123, E126, E127, and E128 in the ironic
code base:
E123 - closing bracket does not match indentation of opening
bracket’s line
E126 - continuation line over-indented for hanging indent
E127 - continuation line over-indented for visual indent
E128 - continuation line under-indented for visual indent
This fixes any parts of the current code which fails these rules and
removes these rules from the tox.ini flake8 ignore list.
Change-Id: Ia96582b5e9abc088d6c1694afc93c59be4a4065c
Closes-Bug: 1421522
Diffstat (limited to 'ironic/common/hash_ring.py')
-rw-r--r-- | ironic/common/hash_ring.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ironic/common/hash_ring.py b/ironic/common/hash_ring.py index b95bba103..2602ddcfb 100644 --- a/ironic/common/hash_ring.py +++ b/ironic/common/hash_ring.py @@ -83,7 +83,7 @@ class HashRing(object): self.replicas = replicas if replicas <= len(hosts) else len(hosts) except TypeError: raise exception.Invalid( - _("Invalid hosts supplied when building HashRing.")) + _("Invalid hosts supplied when building HashRing.")) self._host_hashes = {} for host in hosts: @@ -114,7 +114,7 @@ class HashRing(object): return position if position < len(self._partitions) else 0 except TypeError: raise exception.Invalid( - _("Invalid data supplied to HashRing.get_hosts.")) + _("Invalid data supplied to HashRing.get_hosts.")) def get_hosts(self, data, ignore_hosts=None): """Get the list of hosts which the supplied data maps onto. @@ -197,4 +197,4 @@ class HashRingManager(object): return self.ring[driver_name] except KeyError: raise exception.DriverNotFound( - _("The driver '%s' is unknown.") % driver_name) + _("The driver '%s' is unknown.") % driver_name) |