我是否需要显式记录哨兵在 Django 中工作的消息
我已经安装了 Sentry 来记录消息。我是哨兵新手,所以我不知道它是如何工作的。
它是否只记录那些用记录器(“错误某事”)放入我的文件中的消息,或者发生什么错误,它会自动记录它
假设我没有在我的视图中编写任何日志语句。现在,如果我收到任何异常,那么哨兵会记录它,或者我必须对哨兵的每个异常进行编程
是否有任何方法可以自动记录所有错误而无需输入任何代码,因为我不知道会发生什么类型的异常
I have installed Sentry for messages logging. I am new to sentry so i don't how it works.
Does it logs only those messages which put in my files with logger ("error something")
or whatever error occurs it automatically logs it
Suppose i have not written any log statement in my view. Now if i get any exception then will sentry logs it or i have to program every exception for sentry
is there any way to automatically logs all error without entering any code because i don't know what type of exceptions can occur
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Sentry 自动捕获所有异常并记录它们。至于日志记录本身(使用记录器),默认情况下它不会捕获这些日志记录。你必须设置它。
您可以在此处查看如何设置日志记录。警告:一开始似乎确实很难做到。
编辑:摘自官方文档(07/26/2018):
Sentry auto catches all exceptions and logs them. As for logging itself (using logger), it doesn't catch those by default. You have to set it up.
You may view how to setup logging here. Warning: it does seem difficult do to at first.
Edit: Excerpt from official docs (07/26/2018):