You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using logrus with the evalphobia/logrus_sentry middleware to both log errors to the console and send them to Sentry.
The middleware allows to specify certain fields that have a special meaning on Sentry, such as the full HTTP request object. However, passing those fields to the logrus.WithFields() function causes them to also display on the terminal, that is not what one may want: if you put it the entire web request, it actually becomes hard to read.
So, I'm passing the fields just to have them passed on to Sentry, but I don't want them to display on the terminal.
I thought about a HideCustomFields boolean option in the TextFormatter, that solves this use case without breaking any interface.
Thanks
The text was updated successfully, but these errors were encountered:
Evalphobia/logrus_sentry ara yazılımıyla logrus'u hem hataları konsola kaydetmek hem de Sentry'ye göndermek için kullanıyorum.
Ara yazılım, tam HTTP istek nesnesi gibi Sentry'de özel bir anlamı olan belirli alanları belirlemeye izin verir. Ancak, bu alanları logrus.WithFields() işlevine geçirmek, bunların terminalde de görüntülenmesine neden olur, isteyebileceği şey bu değildir: tüm web isteğini koyarsanız, aslında okunması zorlaşır.
Bu yüzden, alanları sadece Sentry'ye iletmeleri için geçiyorum ama onların terminalde görüntülenmesini istemiyorum.
TextFormatter'da bu kullanım durumunu herhangi bir arayüzü bozmadan çözen bir HideCustomFields boole seçeneği düşündüm.
Hello,
I'm using logrus with the evalphobia/logrus_sentry middleware to both log errors to the console and send them to Sentry.
The middleware allows to specify certain fields that have a special meaning on Sentry, such as the full HTTP request object. However, passing those fields to the logrus.WithFields() function causes them to also display on the terminal, that is not what one may want: if you put it the entire web request, it actually becomes hard to read.
So, I'm passing the fields just to have them passed on to Sentry, but I don't want them to display on the terminal.
I thought about a HideCustomFields boolean option in the TextFormatter, that solves this use case without breaking any interface.
Thanks
The text was updated successfully, but these errors were encountered: