core.sentry =========== .. py:module:: core.sentry Classes ------- .. autoapisummary:: core.sentry.OneGovCloudIntegration core.sentry.CoreRequestExtractor Functions --------- .. autoapisummary:: core.sentry._capture_exception core.sentry._make_event_processor Module Contents --------------- .. py:class:: OneGovCloudIntegration(with_wsgi_middleware: bool = True) Bases: :py:obj:`sentry_sdk.integrations.Integration` A Sentry SDK integration for OneGov Cloud, which relies on :class:`onegov.core.request.CoreRequest` to forward more detailed information to Sentry. .. py:attribute:: identifier :value: 'onegov-cloud' String unique ID of integration type .. py:attribute:: transaction_style :value: 'path' .. py:attribute:: with_wsgi_middleware :value: True .. py:method:: setup_once() -> None :staticmethod: Initialize the integration. This function is only called once, ever. Configuration is not available at this point, so the only thing to do here is to hook into exception handlers, and perhaps do monkeypatches. Inside those hooks `Integration.current` can be used to access the instance again. .. py:class:: CoreRequestExtractor(request: Any) Bases: :py:obj:`sentry_sdk.integrations._wsgi_common.RequestExtractor` Base class for request extraction. .. py:attribute:: request :type: core.request.CoreRequest .. py:method:: env() -> _typeshed.wsgi.WSGIEnvironment .. py:method:: cookies() -> webob.cookies.RequestCookies .. py:method:: raw_data() -> str .. py:method:: form() -> dict[str, str] .. py:method:: files() -> dict[str, webob.request._FieldStorageWithFile] .. py:method:: size_of_file(postdata: webob.request._FieldStorageWithFile) -> int .. py:function:: _capture_exception(exc_info: sentry_sdk.utils.ExcInfo) -> None .. py:function:: _make_event_processor(weak_request: collections.abc.Callable[[], core.request.CoreRequest | None], integration: OneGovCloudIntegration) -> sentry_sdk._types.EventProcessor