Error notifications
Is it possible to setup email notifications for errors? Ideally with some batching logic.
21 Replies
There's currently no way to do this. If you need in app monitoring, you should use Sentry!
If you want to see when Gadget is down, subscribe to the Gadget status page
got it thanks
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
+1 to sentry. very generous to free tier + all sorts of aggregation and alerting capabilities built in
Thanks - trying to set it up. I have the DSN in there. Maybe it just takes a minute or two to show up but I've gotten errors to log and I'm not seeing them in sentry yet.
I checked the docs and they mentioned
api.testSentry()
which doesn't appear to exist - maybe the docs are outdated?
https://docs.gadget.dev/guides/plugins/sentry#uncaught-exceptionsSentry - Developer Docs - Gadget
Gadget Docs

Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
😅
doc scan failure
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
I'll sit tight for a bit 😅 thanks man
Still nothing in sentry. Been 20 minutes. Would be nice if the Sentry plugin show'd some kind of connected state when credentials are validated like shopify does.
I double checked the DSN which I'd copied and pasted in.


Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
Could you please share the URL of your application so I can take a look? I've had no issues setting up my Sentry connection
@Antoine sure here you go - https://clhom.gadget.app/edit/production/connections/sentry
@Aurélien (quasar.work)
1 - no just wait straight to prod on this one
2a yeah
2b no
3- no just tried this now doesn't seem to have helped
4- doesn't help
I think that you need to first add the connection in development in order to have production work. If you try adding the DSN to development then deploy again, let me know if it works
We might have to change the way that this works
ah
I'll try that
I did development first and it's working now in prod at least for a test I did in the api playground.
That one came through to sentry within about 5 seconds.
But this other error that came from within the app hasn't gotten over in over 10 minutes:
Also question - does sentry send the logged-in user email when available? I'd imagine it wouldn't have any way of doing that? If so, I might as well just implement the sentry integration myself since we'll want to do that in this case.

Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
yeah just a little surprised it wasn't more solid out of the box
but yeah I'll just set it up myself
thanks again for the feedback!
Where would be the best place to require(instrument.js)? (docs)
Mostly what I need to cover are api routes - I'm not sure there's a single entrypoint for them where I can drop it in?
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
cool yeah I tried one of those once for something else and didn't seem to be able to get it to run but I'll try again
Hmm got it initializing in the boot plugin but doesn't seem to be automatically instrumenting all the error handling - ah well I'll come back to this a bit later I guess
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View