File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -224,10 +224,6 @@ def main():
224224 )
225225
226226 for action in actions :
227- # Configure a logger for each action, giving it the last part of its uuid as logger name.
228- action_component_name = action .uuid .split ("." )[- 1 ]
229- configure_streamdeck_logger (name = action_component_name , plugin_uuid = plugin_uuid )
230-
231227 manager .register_action (action )
232228
233229 manager .run ()
Original file line number Diff line number Diff line change 77from streamdeck .actions import ActionRegistry
88from streamdeck .command_sender import StreamDeckCommandSender
99from streamdeck .models .events import event_adapter
10+ from streamdeck .utils .logging import configure_streamdeck_logger
1011from streamdeck .websocket import WebSocketClient
1112
1213
@@ -55,11 +56,15 @@ def __init__(
5556 self ._registry = ActionRegistry ()
5657
5758 def register_action (self , action : Action ) -> None :
58- """Register an action with the PluginManager.
59+ """Register an action with the PluginManager, and configure its logger .
5960
6061 Args:
6162 action (Action): The action to register.
6263 """
64+ # First, configure a logger for the action, giving it the last part of its uuid as name.
65+ action_component_name = action .uuid .split ("." )[- 1 ]
66+ configure_streamdeck_logger (name = action_component_name , plugin_uuid = self .uuid )
67+
6368 self ._registry .register (action )
6469
6570 def run (self ) -> None :
You can’t perform that action at this time.
0 commit comments