MCPcopy Create free account
hub / github.com/1Panel-dev/MaxKB / is_valid_start_node

Method is_valid_start_node

apps/application/flow/common.py:241–246  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

239 self.is_valid_work_flow(next_node)
240
241 def is_valid_start_node(self):
242 start_node_list = [node for node in self.nodes if node.id == 'start-node']
243 if len(start_node_list) == 0:
244 raise AppApiException(500, _('The starting node is required'))
245 if len(start_node_list) > 1:
246 raise AppApiException(500, _('There can only be one starting node'))
247
248 def is_valid_model_params(self):
249 node_list = [node for node in self.nodes if (

Callers 1

is_validMethod · 0.95

Calls 1

AppApiExceptionClass · 0.90

Tested by

no test coverage detected