napari.utils.notifications.ErrorNotification

class napari.utils.notifications.ErrorNotification(exception: BaseException, *args, **kwargs)[source]

Bases: napari.utils.notifications.Notification

Notification at an Error severity level.

Methods

as_html()

as_text()

from_exception(exc, **kwargs)

from_warning(warning, **kwargs)

Attributes

blocked

This boolean property indicates whether the event will be delivered to event callbacks.

handled

This boolean property indicates whether the event has already been acted on by an event handler.

message

native

source

The object that the event applies to (i.e.

sources

List of objects that the event applies to (i.e.

type

Details

property blocked: bool

This boolean property indicates whether the event will be delivered to event callbacks. If it is set to True, then no further callbacks will receive the event. When possible, it is recommended to use Event.handled rather than Event.blocked.

property handled: bool

This boolean property indicates whether the event has already been acted on by an event handler. Since many handlers may have access to the same events, it is recommended that each check whether the event has already been handled as well as set handled=True if it decides to act on the event.

property source: Any

The object that the event applies to (i.e. the source of the event).

property sources: List[Any]

List of objects that the event applies to (i.e. are or have been a source of the event). Can contain multiple objects in case the event traverses a hierarchy of objects.