Skip to content

← control_flow package

Throw

Throw an Exception.

This will interrupt the execution at the current point and fall through to the nearest enclosing Exception Guard node that lists the thrown exception type (or a more general one) in its list of exceptions to catch. For the hierarchy of throwable exceptions, see also Python's documentation. More Info... Version 1.0.0

Ports/Properties

result

Result of the graph.

  • verbose name: Result
  • default value: None
  • port type: DataPort
  • value type: object (can be None)
  • data direction: OUT

exception_type

Exception type to throw. You can find documentation about these types in the Python documentation.

  • verbose name: Exception Type
  • default value: RuntimeError
  • port type: ComboPort
  • value type: str (can be None)

message

Message to include in the exception.

  • verbose name: Message
  • default value: Exception message
  • port type: StringPort
  • value type: str (can be None)

cause

Causing exception. If this is set, the provided exception will be recorded as the cause of the exception being thrown. This is useful for chaining exceptions together.

  • verbose name: Cause
  • default value: None
  • port type: Port
  • value type: Exception (can be None)

set_breakpoint

Set a breakpoint on this node. If this is enabled, your debugger (if one is attached) will trigger a breakpoint.

  • verbose name: Set Breakpoint (Debug Only)
  • default value: False
  • port type: BoolPort
  • value type: bool (can be None)

metadata

User-definable meta-data associated with the node. Usually reserved for technical purposes.

  • verbose name: Metadata
  • default value: {}
  • port type: DictPort
  • value type: dict (can be None)