*: fix general Linting errors

This commit is contained in:
Jens Langhammer 2020-08-19 10:49:14 +02:00
parent c7a2410b1d
commit 0394adaf46
3 changed files with 7 additions and 6 deletions

View File

@ -81,7 +81,7 @@ class TestSourceOAuth(SeleniumTestCase):
interval=5 * 100 * 1000000, interval=5 * 100 * 1000000,
start_period=1 * 100 * 1000000, start_period=1 * 100 * 1000000,
), ),
volumes={abspath(CONFIG_PATH): {"bind": "/config.yml", "mode": "ro",}}, volumes={abspath(CONFIG_PATH): {"bind": "/config.yml", "mode": "ro"}},
) )
while True: while True:
container.reload() container.reload()

View File

@ -85,15 +85,16 @@ class FlowExecutorView(View):
return self.handle_invalid_flow(exc) return self.handle_invalid_flow(exc)
# We don't save the Plan after getting the next stage # We don't save the Plan after getting the next stage
# as it hasn't been successfully passed yet # as it hasn't been successfully passed yet
self.current_stage = self.plan.next() next_stage = self.plan.next()
if not next_stage:
LOGGER.debug("f(exec): no more stages, flow is done.")
return self._flow_done()
self.current_stage = next_stage
LOGGER.debug( LOGGER.debug(
"f(exec): Current stage", "f(exec): Current stage",
current_stage=self.current_stage, current_stage=self.current_stage,
flow_slug=self.flow.slug, flow_slug=self.flow.slug,
) )
if not self.current_stage:
LOGGER.debug("f(exec): no more stages, flow is done.")
return self._flow_done()
stage_cls = self.current_stage.type() stage_cls = self.current_stage.type()
self.current_stage_view = stage_cls(self) self.current_stage_view = stage_cls(self)
self.current_stage_view.args = self.args self.current_stage_view.args = self.args

View File

@ -32,7 +32,7 @@ class PolicyResult:
"""Small data-class to hold policy results""" """Small data-class to hold policy results"""
passing: bool passing: bool
messages: Tuple[str] messages: Tuple[str, ...]
def __init__(self, passing: bool, *messages: str): def __init__(self, passing: bool, *messages: str):
self.passing = passing self.passing = passing