Skip to content

Commit

Permalink
ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
sanderegg committed Aug 21, 2023
1 parent 7aaee75 commit f397a6c
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ async def _get_service_latest_task(service_id: str) -> Mapping[str, Any]:
filters={"service": f"{service_id}"}
)
if not service_associated_tasks:
raise DockerServiceNotFoundError(service_id=service_id) # noqa: TRY301
raise DockerServiceNotFoundError(service_id=service_id)

# The service might have more then one task because the
# previous might have died out.
Expand Down Expand Up @@ -183,7 +183,7 @@ async def _get_task_data_when_service_running(service_id: str) -> Mapping[str, A
service_state = task["Status"]["State"]

if service_state not in TASK_STATES_RUNNING:
raise TryAgain()
raise TryAgain
return task

task = await _get_task_data_when_service_running(service_id=service_id)
Expand Down Expand Up @@ -457,7 +457,7 @@ async def _update_service_spec(
e.status == status.HTTP_500_INTERNAL_SERVER_ERROR
and "out of sequence" in e.message
):
raise TryAgain() from e
raise TryAgain from e
raise


Expand Down

0 comments on commit f397a6c

Please sign in to comment.