diff --git a/lang/python/python-sentry-sdk/Makefile b/lang/python/python-sentry-sdk/Makefile index c65bda308f..261fa76cc2 100644 --- a/lang/python/python-sentry-sdk/Makefile +++ b/lang/python/python-sentry-sdk/Makefile @@ -8,11 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=python-sentry-sdk -PKG_VERSION:=1.29.2 +PKG_VERSION:=2.57.0 PKG_RELEASE:=1 PYPI_NAME:=sentry-sdk -PKG_HASH:=a99ee105384788c3f228726a88baf515fe7b5f1d2d0f215a03d194369f158df7 +PYPI_SOURCE_NAME:=sentry_sdk +PKG_HASH:=4be8d1e71c32fb27f79c577a337ac8912137bba4bcbc64a4ec1da4d6d8dc5199 PKG_MAINTAINER:=Josef Schlehofer PKG_LICENSE:=MIT diff --git a/lang/python/python-sentry-sdk/test.sh b/lang/python/python-sentry-sdk/test.sh new file mode 100755 index 0000000000..e48569577b --- /dev/null +++ b/lang/python/python-sentry-sdk/test.sh @@ -0,0 +1,29 @@ +#!/bin/sh + +[ "$1" = python3-sentry-sdk ] || exit 0 + +python3 - << 'EOF' +import sentry_sdk +from sentry_sdk import capture_message, capture_exception +from sentry_sdk.transport import Transport + +class NoopTransport(Transport): + def __init__(self): + self.events = [] + def capture_envelope(self, envelope): + self.events.append(envelope) + +transport = NoopTransport() +sentry_sdk.init(dsn="", transport=transport) + +# capture_message should not raise +capture_message("test message") + +# capture_exception should not raise +try: + raise ValueError("test error") +except ValueError: + capture_exception() + +sentry_sdk.flush() +EOF