l.s.w.e.ErrorReportingUtility : class documentation

Part of lp.services.webapp.errorlog View In Hierarchy

No class docstring
Method __init__ Undocumented
Method configure Configure the utility using the named section from the config.
Method oops_prefix Get the current effective oops prefix.
Method raising See IErrorReportingUtility.raising()
Method oopsMessage Add an oops message to be included in oopses from this context.
Method addOopsMessage Add a message to the current oops accumulator.
Method _filter_bad_urls_by_referer Filter if the report was generated because of a bad offsite url.
Method _filter_deliberate_db_outages Undocumented
Method _attach_messages merges self._oops_messages into the report req_vars variable.
def __init__(self):
Undocumented
def configure(self, section_name=None, config_factory=oops.Config, publisher_adapter=None, publisher_helpers=oops.publishers):
Configure the utility using the named section from the config.

The 'error_reports' section is used if section_name is None.

@property
def oops_prefix(self):
Get the current effective oops prefix.
def raising(self, info, request=None):
See IErrorReportingUtility.raising()
def _filter_bad_urls_by_referer(self, report):
Filter if the report was generated because of a bad offsite url.
def _filter_deliberate_db_outages(self, report):
Undocumented
def _attach_messages(self, report, context):
merges self._oops_messages into the report req_vars variable.
@contextlib.contextmanager
def oopsMessage(self, message):
Add an oops message to be included in oopses from this context.

The message will be removed when the scope is exited, so this is useful for messages that are relevant only to errors raised during part of the request.

Warning: This is not threadsafe at present, because there is only one ErrorReportingUtility per process.

ParametersmessageUnicode message.
def addOopsMessage(self, message):
Add a message to the current oops accumulator.

Warning: This is not threadsafe at present, because there is only one ErrorReportingUtility per process.

ParametersmessageUnicode message.
ReturnsKey for this message.
API Documentation for Launchpad, generated by pydoctor at 2022-06-16 00:00:12.