Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace SentryWrapperLogger by slog-sentry #673

Merged
merged 1 commit into from
Sep 7, 2024
Merged

Conversation

finnng
Copy link
Contributor

@finnng finnng commented Sep 5, 2024

  • Replace SentryWrapperLogger by slog-sentry in Migrate from logbuch to slog #480
    • Add missing method Fatal to Log()
    • Add context http_request to Log().Request(r) to add the userID to the context in BeforeSend of initSentry
  • Correct some sentry logging with slog structure

@finnng finnng changed the title Replace SentryLogWrapper by slog-sentry Replace SentryWrapperLogger by slog-sentry Sep 5, 2024
@finnng
Copy link
Contributor Author

finnng commented Sep 5, 2024

hi @muety this PR is ready to review

@muety
Copy link
Owner

muety commented Sep 6, 2024

Thanks a lot! Will have a look tomorrow.

@muety muety merged commit ddffd46 into muety:master Sep 7, 2024
7 checks passed
@muety
Copy link
Owner

muety commented Sep 7, 2024

Thanks! Passing the request wasn't working properly, as Sentry complained it couldn't serialize an http.Request object to JSON. I fixed it by passing the request as stated on slog-sentry's docs and added another couple of minor changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants