MCPcopy Create free account
hub / github.com/aaPanel/BaoTa / __init__

Method __init__

mod/project/node/task_flow/file_task.py:355–370  ·  view source on GitHub ↗
(self, task: TransferTask,
                 call_update: Callable[[Any], None],
                 exclude_nodes: List[int] = None,
                 the_log_id: int = None,
                 )

Source from the content-addressed store, hash-verified

353class NodeFiletransferTask(object):
354
355 def __init__(self, task: TransferTask,
356 call_update: Callable[[Any], None],
357 exclude_nodes: List[int] = None,
358 the_log_id: int = None,
359 ):
360 self.task = task
361 src_node = task.src_node
362 self.exclude_nodes = exclude_nodes or []
363 self.srv = ServerNode(src_node["address"],src_node["api_key"], src_node["app_key"], src_node["name"])
364 self.the_log_id = max(the_log_id, 0) if isinstance(the_log_id, int) else 0
365 self.call_update = call_update
366 self.default_status_data = {
367 "task_id": self.task.id,
368 "task_type": "file",
369 }
370 self.status_dict = dict() # 状态数据
371
372 def start(self):
373 fdb = TaskFlowsDB()

Callers

nothing calls this directly

Calls 1

ServerNodeClass · 0.90

Tested by

no test coverage detected