hacking: Reenable E275
Get up to speed with current Python style. Change-Id: Ib9f9a8bc6720ca8e1b916b2fa1583982859b08ae
This commit is contained in:
parent
df5b1fd5b5
commit
b87d45b3c8
@ -182,8 +182,7 @@ class API(base.Base):
|
|||||||
idx = 0
|
idx = 0
|
||||||
while idx < len(services):
|
while idx < len(services):
|
||||||
srv = services[idx]
|
srv = services[idx]
|
||||||
if(self._az_matched(srv, availability_zone) and
|
if (self._az_matched(srv, availability_zone) and srv.is_up):
|
||||||
srv.is_up):
|
|
||||||
return srv.host
|
return srv.host
|
||||||
idx = idx + 1
|
idx = idx + 1
|
||||||
return None
|
return None
|
||||||
|
@ -800,8 +800,7 @@ port_speed!N/A
|
|||||||
value1 = filter1.split('=')[1]
|
value1 = filter1.split('=')[1]
|
||||||
value2 = filter2.split('=')[1]
|
value2 = filter2.split('=')[1]
|
||||||
for v in ports:
|
for v in ports:
|
||||||
if(str(v[5]) == value1 and str(
|
if (str(v[5]) == value1 and str(v[7]) == value2):
|
||||||
v[7]) == value2):
|
|
||||||
rows.append(v)
|
rows.append(v)
|
||||||
else:
|
else:
|
||||||
value = kwargs['filtervalue'].split('=')[1]
|
value = kwargs['filtervalue'].split('=')[1]
|
||||||
|
5
tox.ini
5
tox.ini
@ -233,9 +233,6 @@ commands =
|
|||||||
#
|
#
|
||||||
# E251 unexpected spaces around keyword / parameter equals
|
# E251 unexpected spaces around keyword / parameter equals
|
||||||
# reason: no improvement in readability
|
# reason: no improvement in readability
|
||||||
# E275: missing whitespace after keyword
|
|
||||||
# reason: many failures newly triggered in pycodestyle 2.9.0,
|
|
||||||
# evaluate if fixing is worthwhile
|
|
||||||
# E402 module level import not at top of file
|
# E402 module level import not at top of file
|
||||||
# reason: there are numerous places where we import modules
|
# reason: there are numerous places where we import modules
|
||||||
# later for legitimate reasons
|
# later for legitimate reasons
|
||||||
@ -251,7 +248,7 @@ commands =
|
|||||||
# reason: no real benefit
|
# reason: no real benefit
|
||||||
# G200 Logging statements should not include the exception
|
# G200 Logging statements should not include the exception
|
||||||
# reason: Many existing cases of this that may be legitimate
|
# reason: Many existing cases of this that may be legitimate
|
||||||
ignore = E251,E275,E402,W503,W504,H101,G200
|
ignore = E251,E402,W503,W504,H101,G200
|
||||||
# H904 Delay string interpolations at logging calls.
|
# H904 Delay string interpolations at logging calls.
|
||||||
enable-extensions = H106,H203,H904
|
enable-extensions = H106,H203,H904
|
||||||
exclude = .git,.venv,.tox,dist,tools,doc/ext,*egg,build
|
exclude = .git,.venv,.tox,dist,tools,doc/ext,*egg,build
|
||||||
|
Loading…
x
Reference in New Issue
Block a user