
[英]How do I solve a version confliction problem between albumentations and sentry-sdk?
[英]How do I get Sentry reference ID in html template using sentry-sdk?
由于raven
已被弃用,我需要一种替代方法来在我的 html 模板中显示 Sentry 参考 ID。
以前的版本从示例中看起来像这样:
<p>You've encountered an error, oh noes!</p>
{% if request.sentry.id %}
<p>
If you need assistance, you may reference this error as
<strong>{{ request.sentry.id }}</strong>.
</p>
{% endif %}
我现在该怎么做? 我尝试使用sentry_sdk.capture_exception()
或sentry_sdk.last_event_id()
方法。 第一个在我的模板中返回无,第二个看起来是我现在正在寻找的。
Sentry 有一个新的用户反馈功能。
以下是文档: https ://docs.sentry.io/platforms/python/guides/django/enriching-events/user-feedback/
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.