inveniosoftware / invenio-rest

REST API support for Invenio.
https://invenio-rest.readthedocs.io
MIT License
2 stars 41 forks source link

sentry-sdk >=2.0.0 is not supported #135

Open jma opened 5 months ago

jma commented 5 months ago

Package version (if known): 1.30

Describe the bug

The following error can occurs with the new version of sentry-sdk:

    def api_errorhandler(e):
        if isinstance(e, RESTException):
            return e.get_response()
        elif isinstance(e, HTTPException) and e.description:
            kwargs["message"] = e.description
        if kwargs.get("status", 400) >= 500:
>           sentry_event_id = sentry_sdk.last_event_id()
E           AttributeError: module 'sentry_sdk' has no attribute 'last_event_id'
site-packages/invenio_rest/views.py:44: AttributeError