Hey, there! I use Heroku to host my Nuxt application and I use the Heroku Labs Dyno Metadata addon to track releases. The issue I’m having is that when I initiate Sentry in my nuxt.config.js
file, the environment variable that Heroku creates (HEROKU_SLUG_COMMIT
) has not yet updated.
So, essentially, every error sent to Sentry has the previous release attached to it. I’m trying to figure out a way to grab environment variables in Nuxt during runtime – not sure if that’s possible – and if I can, I was wondering if there was a way to add the release information after init. So, I’d init in my config file and then when my global layout component mounts I would add the release to the Sentry config in the mounted hook.
I’ve tried Sentry.setRelease()
but I get an error – it’s not a function.
Help! Thanks!