hawat.events module

This module contains couple of simple helpers for working with IDEA messages.

hawat.events.db_cursor()[source]

Convenience method.

hawat.events.db_get()[source]

Opens a new database connection if there is none yet for the current application context.

Returns:

Database storage handler.

Return type:

flask_sqlalchemy.SQLAlchemy

hawat.events.db_init(app)[source]

Initialize connection to event database.

hawat.events.db_settings(app)[source]

Return database settings from Mentat core configurations.

Returns:

Database settings.

Return type:

dict

hawat.events.get_after_cleanup(dt: datetime) bool[source]

Returns True if there is the cleanup module present and the provied time comes before the latest cleanup time derived from the cleanup module configuration. Otherwise returns False.

Please note, that if the cleanup module is present, this function will return these values regardless of the running state of the module.

hawat.events.get_event_categories()[source]

Return list of all available event categories.

hawat.events.get_event_classes()[source]

Return list of all available event classes.

hawat.events.get_event_detector_types()[source]

Return list of all available event detector types.

hawat.events.get_event_detectors()[source]

Return list of all available event detectors.

hawat.events.get_event_enums()[source]
hawat.events.get_event_form_choices()[source]
hawat.events.get_event_inspection_errs()[source]

Return list of all available event inspection errors.

hawat.events.get_event_protocols()[source]

Return list of all available event protocols.

hawat.events.get_event_severities()[source]

Return list of all available event severities.

hawat.events.get_event_source_types()[source]

Return list of all available event source types.

hawat.events.get_event_target_types()[source]

Return list of all available event target types.