init(type:args:traceback:)

Initializes a Python exception.

Declaration

init(
    type: Object,
    args: [Object],
    traceback: Traceback? = nil
) throws

Parameters

  • type: The exception type.

  • args: The exception’s args.

  • traceback: An optional Traceback.

Throws

An Exception occurred while constructing the exception object.