Skip to content

Commit 9884fee

Browse files
committed
linting fix
1 parent 4901d34 commit 9884fee

2 files changed

Lines changed: 10 additions & 10 deletions

File tree

aikido_zen/background_process/commands/put_event.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@ def run(cls, context: CommandContext, request: PutEventReq):
2222
context.queue.put(request.event)
2323

2424
@classmethod
25-
def generate(cls, event) -> Payload:
26-
return Payload(cls, PutEventReq(event))
25+
def generate(cls, request) -> Payload:
26+
return Payload(cls, PutEventReq(request))

aikido_zen/helpers/ipc/command_types.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,13 @@ def send(self, response):
1111
self.connection.send(response)
1212

1313

14+
class Payload:
15+
def __init__(self, command, request):
16+
self.identifier = command.identifier()
17+
self.returns_data = command.returns_data()
18+
self.request = request
19+
20+
1421
class Command(ABC):
1522
@classmethod
1623
@abstractmethod
@@ -29,12 +36,5 @@ def run(cls, context: CommandContext, request):
2936

3037
@classmethod
3138
@abstractmethod
32-
def generate(cls, *args, **kwargs):
39+
def generate(cls, request) -> Payload:
3340
pass
34-
35-
36-
class Payload:
37-
def __init__(self, command: type[Command], request):
38-
self.identifier = command.identifier()
39-
self.returns_data = command.returns_data()
40-
self.request = request

0 commit comments

Comments
 (0)