Skip to content

Commit 9080679

Browse files
committed
style: ruff
Signed-off-by: Yves Bastide <[email protected]>
1 parent 995a937 commit 9080679

File tree

5 files changed

+6
-7
lines changed

5 files changed

+6
-7
lines changed

simpleflow/process/_supervisor.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ def terminate(self):
208208
Terminate all worker processes managed by this Supervisor.
209209
"""
210210
self._terminating = True
211-
logger.info("process: will stop workers, this might take up several minutes. " "Please, be patient.")
211+
logger.info("process: will stop workers, this might take up several minutes. Please, be patient.")
212212
self._killall()
213213

214214
def _killall(self):

simpleflow/swf/mapper/querysets/activity.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def domain(self, value: Domain):
4343
from simpleflow.swf.mapper.models.domain import Domain
4444

4545
if not isinstance(value, Domain):
46-
err = "domain property has to be of" f"swf.model.domain.Domain type, not {type(value)!r}"
46+
err = f"domain property has to be of swf.model.domain.Domain type, not {type(value)!r}"
4747
raise TypeError(err)
4848
self._domain = value
4949

simpleflow/swf/mapper/querysets/workflow.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def domain(self) -> Domain | None:
4848
@domain.setter
4949
def domain(self, value: Domain):
5050
if not isinstance(value, Domain):
51-
err = "domain property has to be of" f"swf.model.domain.Domain type, not {type(value)!r}"
51+
err = f"domain property has to be of swf.model.domain.Domain type, not {type(value)!r}"
5252
raise TypeError(err)
5353
self._domain = value
5454

simpleflow/task.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,7 @@ def name(self):
102102

103103
def __repr__(self):
104104
return (
105-
f"{self.__class__.__name__}(activity={self.activity}, args={self.args}, kwargs={self.kwargs},"
106-
f" id={self.id})"
105+
f"{self.__class__.__name__}(activity={self.activity}, args={self.args}, kwargs={self.kwargs}, id={self.id})"
107106
)
108107

109108
def execute(self):

tests/integration/workflow.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,13 @@ def get_uuid(unused=None):
3434

3535
@activity.with_attributes(task_list="quickstart", version="example")
3636
def increment(x):
37-
print("increment: %d" % x)
37+
print(f"increment: {x:d}")
3838
return x + 1
3939

4040

4141
@activity.with_attributes(task_list="quickstart", version="example")
4242
def double(y):
43-
print("double: %d" % y)
43+
print(f"double: {y:d}")
4444
return y * 2
4545

4646

0 commit comments

Comments
 (0)