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(fastify): Warn if fastify is not instrumented #11917

Merged
merged 1 commit into from
May 7, 2024

Conversation

mydea
Copy link
Member

@mydea mydea commented May 6, 2024

When using setupFastifyErrorHandler(app) we can check if the app was correctly instrumented.

Not sure how to best test this - I tested this manually in a test app and could verify that the log was printed when requiring fastify before calling init!

When using `setupFastifyErrorHandler(app)` we can check if the app was correctly instrumented.
@mydea mydea requested review from HazAT, lforst and s1gr1d May 6, 2024 15:22
@mydea mydea self-assigned this May 6, 2024
Copy link
Contributor

github-actions bot commented May 6, 2024

size-limit report 📦

Path Size
@sentry/browser 21.65 KB (0%)
@sentry/browser (incl. Tracing) 32.67 KB (0%)
@sentry/browser (incl. Tracing, Replay) 68.01 KB (0%)
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 61.41 KB (0%)
@sentry/browser (incl. Tracing, Replay with Canvas) 72.05 KB (0%)
@sentry/browser (incl. Tracing, Replay, Feedback) 84.15 KB (0%)
@sentry/browser (incl. Feedback) 37.66 KB (0%)
@sentry/browser (incl. sendFeedback) 26.21 KB (0%)
@sentry/browser (incl. FeedbackAsync) 30.84 KB (0%)
@sentry/react 24.33 KB (0%)
@sentry/react (incl. Tracing) 35.63 KB (0%)
@sentry/vue 25.48 KB (0%)
@sentry/vue (incl. Tracing) 34.46 KB (0%)
@sentry/svelte 21.78 KB (0%)
CDN Bundle 24.14 KB (0%)
CDN Bundle (incl. Tracing) 34.04 KB (0%)
CDN Bundle (incl. Tracing, Replay) 67.71 KB (0%)
CDN Bundle (incl. Tracing, Replay, Feedback) 72.92 KB (0%)
CDN Bundle - uncompressed 70.99 KB (0%)
CDN Bundle (incl. Tracing) - uncompressed 100.98 KB (0%)
CDN Bundle (incl. Tracing, Replay) - uncompressed 210.59 KB (0%)
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 223.87 KB (0%)
@sentry/nextjs (client) 34.86 KB (0%)
@sentry/sveltekit (client) 33.23 KB (0%)
@sentry/node 146.29 KB (0%)

Copy link
Member

@andreiborza andreiborza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mydea mydea merged commit 29e89e1 into develop May 7, 2024
83 checks passed
@mydea mydea deleted the fn/fastify-warn-not-instrumented branch May 7, 2024 14:20
andreiborza pushed a commit that referenced this pull request May 16, 2024
When using `setupFastifyErrorHandler(app)` we can check if the app was
correctly instrumented.

Not sure how to best test this - I tested this manually in a test app
and could verify that the log was printed when requiring fastify before
calling init!
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.

None yet

2 participants