Skip to content

Alter backtrace for Sentry.capture_message #1545

@Math3v

Description

@Math3v

Describe the idea
We have a custom wrapping module before Sentry reporting that exposes a custom API to match the previous service we used to track errors.
We leverage config.backtrace_cleanup_callback which however only alters stacktraces for exceptions, but not messages.
We would like to use Sentry's Issue Owners feature. If all messages come from our wrapping module, then all issues would have the same owner assigned.

Possible implementation
Solution 1:
Run both exceptions and messages through backtrace_cleanup_callback hook.

Solution 2:
Enable passing custom backtrace to capture_message function.

Metadata

Metadata

Assignees

No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions