MCPcopy Create free account
hub / github.com/runhey/OnmyojiAutoScript / __init__

Method __init__

script.py:36–48  ·  view source on GitHub ↗
(self, config_name: str ='oas')

Source from the content-addressed store, hash-verified

34
35class Script:
36 def __init__(self, config_name: str ='oas') -> None:
37 logger.hr('Start', level=0)
38 self.server = None
39 self.state_queue: Queue = None
40 self.gui_update_task: Callable = None # 回调函数, gui进程注册当每次config更新任务的时候更新gui的信息
41 self.config_name = config_name
42 # Skip first restart
43 self.is_first_task = True
44 # Failure count of tasks
45 # Key: str, task name, value: int, failure count
46 self.failure_record = {}
47 # 运行loop的线程
48 self.loop_thread: Thread = None
49
50 @cached_property
51 def config(self) -> "Config":

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected