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

feat: capture more sentry levels #1104

Merged
merged 2 commits into from
Apr 4, 2024
Merged

Conversation

pauldambra
Copy link
Member

@pauldambra pauldambra commented Mar 30, 2024

For #1060

We register a sentry event processor and only process events with level error

captureMessage events pass through the same processor and can have multiple levels.

We also don't want to change existing behaviour since this could be a high event volume change for people

So this change allows people to opt-in by setting an allowlist of severity levels to capture

You could set '*' to process any sentry message
Or ['error', 'info'] to process default calls to captureException and captureMessage


I did consider changing the emitted event so that captureMessage did not emit $exception but instead event.message as the event but it seems neater that the sentry integration always emits the same event type


message from captureMessage enhanced with PostHog URLs

Screenshot 2024-03-30 at 09 38 18

@pauldambra pauldambra requested a review from a team March 30, 2024 09:03
Copy link

github-actions bot commented Mar 30, 2024

Size Change: +504 B (0%)

Total Size: 944 kB

Filename Size Change
dist/array.full.js 225 kB +126 B (0%)
dist/array.js 124 kB +126 B (0%)
dist/es.js 125 kB +126 B (0%)
dist/module.js 125 kB +126 B (0%)
ℹ️ View Unchanged
Filename Size
dist/exception-autocapture.js 12.1 kB
dist/recorder-v2.js 106 kB
dist/recorder.js 106 kB
dist/surveys-module-previews.js 62 kB
dist/surveys.js 58.3 kB

compressed-size-action

@pauldambra pauldambra added the bump minor Bump minor version when this PR gets merged label Mar 30, 2024
@pauldambra pauldambra merged commit e804970 into main Apr 4, 2024
13 checks passed
@pauldambra pauldambra deleted the feat/capture-more-sentry-levels branch April 4, 2024 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bump minor Bump minor version when this PR gets merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants