Activities

maciejunio

maciejunio posted a new feature request

sentry-module •

idea Performance Monitoring

What problem does this feature solve?

How can i implement https://docs.sentry.io/platforms/javascript/guides/vue/#monitor-performance in this module ?

What does the proposed changes look like?

Completed documentation

abakermi

abakermi posted a new bug report

sentry-module •

bug serverSide not working when using Nuxt programatically

Version

v4.3.4

Reproduction link

https://github.com/abakermi/sentry-demo-production-mode

Steps to reproduce

npm run build && NODE_ENV=production npm run start

What is expected ?

$sentry is defined in fetch(),asyncData(),…

What is actually happening?

$sentry={}

Cogitoergo

Cogitoergo posted a new feature request

sentry-module •

idea Sentry performance tracing

What problem does this feature solve?

Enables @nuxtjs/sentry module to use sentry's performance tracking integrations

MattIPv4

MattIPv4 posted a new feature request

sentry-module •

idea Support for multiple DSNs

What problem does this feature solve?

Due to a complicated org setup and much more, we'd really like to be able to log errors to multiple DSNs.

Further, it'd be really awesome if the release publishing logic also supported being sent to multiple different orgs/projects.

What does the proposed changes look like?

Currently, we define the DSN URL in nuxt.config.js but we set all the environment variables for release publishing -- with that in mind, I imagine the interface for multiple DSNs being as simple as giving an array in nuxt.config.js but I'm unsure what the interface would be for multiple release publishing configs.

felixoi

felixoi posted a new bug report

sentry-module •

bug Deprecation Warning when using this module

Version

v4.2.1

Reproduction link

https://github.com/felixoi/nymph

Steps to reproduce

npm run dev

What is expected ?

No Deprecation Warning

What is actually happening?

ERROR (node:12546) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead.

edus44

edus44 posted a new bug report

sentry-module •

bug Error when mapping client integrations

Version

v4.2.0

Reproduction link

https://github.com/nuxt-community/sentry-module/blob/588e3ec7ef8bbd45d487d93dbd176fdba2f9a77d/lib/plugin.client.js#L17..L21

Steps to reproduce

In this file, the map function is not returning anything:

https://github.com/nuxt-community/sentry-module/blob/588e3ec7ef8bbd45d487d93dbd176fdba2f9a77d/lib/plugin.client.js#L17..L21

What is expected ?

To return the integrations object correctly

What is actually happening?

Returning undefined

Additional comments?

To fix this, use return before the typeof or just remove the curly braces.

MartinMalinda

MartinMalinda posted a new bug report

sentry-module •

bug sentry.client.js not found

Version

v4.2.0

Reproduction link

https://github.com/nuxt-community/sentry-module/blob/963fead523d94661dfc4c597866db66408b7a667/lib/module.js#L147

Steps to reproduce

Install nuxt-sentry 4.2.0 and run nuxt build

What is expected ?

build succeeds

What is actually happening?

✖ Nuxt Fatal Error                                                                                   │
   │                                                                                                        │
   │   Error: Template src not found:                                                                       │
   │   /Users/martinmalinda/web/project/node_modules/@nuxtjs/sentry/lib/sentry.client.js 

Additional comments?

https://github.com/nuxt-community/sentry-module/blob/963fead523d94661dfc4c597866db66408b7a667/lib/module.js#L147 maybe this needs to be adjusted?

marosmola

marosmola posted a new feature request

sentry-module •

idea Plugin not using runtime variables from $config

What problem does this feature solve?

When using application in more than one environment, different configuration settings for sentry module are needed during runtime.

What does the proposed changes look like?

Override default configuration to use runtime config which would have higher priority than using environment variables.

MattIPv4

MattIPv4 posted a new bug report

sentry-module •

bug Getting sourcemaps / releases working

Version

v4.1.3

Reproduction link

https://github.com/cdnjs/static-website

Steps to reproduce

I have the following config in nuxt.config.js:

    sentry: {
        dsn: sentryDsn,
        publishRelease: 'SENTRY_AUTH_TOKEN' in process.env,
        sourceMapStyle: 'hidden-source-map',
    },

sentryDsn is a valid DSN url imported from another config file.

The SENTRY_AUTH_TOKEN environment variable is set during build & start.

.sentryclirc has our org/project set correctly:

[defaults]
org = cloudflare
project = cdnjs-website

When nuxt build is run, it creates the release correctly on Sentry as far as I can tell, using the latest commit hash.

However, when errors are then generated in the app (after nuxt start), they appear in Sentry without any attached release and don't appear to be using the source maps.

What is expected ?

Maybe I'm configuring something wrong, but I would expect errors generated both server-side and client-side to be correctly attached to the release generated during nuxt build and to use the source maps so that the stack trace is useful in Sentry.

What is actually happening?

Issues have no attached release and don't use the source maps, resulting in the stack trace being the raw bundled files which is unusable.

moreinhardt

moreinhardt posted a new question

sentry-module •

Set environment at runtime

Hi!

My nuxt app is inside a docker image and I want to pass different environments at runtime using the Runtime Config instead of hard-coding them into the image when I use env-vars at build time.

I tried creating a plugin that modifies $sentry. This works fine for the DSN, but doesn't work for the environment. Can anyone help me?

export default function ({ $sentry, $config }) {
  $sentry.dsn = $config.sentryDsn // works
  $sentry.config = { environment: $config.sentryEnvironment } // doesn't work
  $sentry.environment = $config.sentryEnvironment // doesn't work either
}
rchl

rchl posted a new bug report

sentry-module •

bug Sentry types don't augment context app in Nuxt 2.13

Version

v4.1.2

Reproduction link

https://codesandbox.io/s/still-brook-uy5cv?file=/plugins/sentry.js

Steps to reproduce

  1. Open plugins/sentry.js and hover app.$sentry in the editor.

What is expected ?

Should have proper Sentry types

What is actually happening?

Has any type.

Additional comments?

Works with v0.7.9 of @nuxt/types

dora-gt

dora-gt posted a new question

sentry-module •

warning: could not determine a source map reference

I installed @nuxtjs/centry but it says it could not determine source map references.

Source Map Upload Report
  Minified Scripts
    ~/_nuxt/0486225a8951595ac408.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/0486225a8951595ac408.js.)
    ~/_nuxt/0585eb10e42d5fba9ca6.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/0585eb10e42d5fba9ca6.js.)
    ~/_nuxt/0b58a16a8c0c54a4574c.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/0b58a16a8c0c54a4574c.js.)
    ~/_nuxt/110da700614c696e75a2.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/110da700614c696e75a2.js.)
    ~/_nuxt/1b10292f0960d55f4d58.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/1b10292f0960d55f4d58.js.)
    ~/_nuxt/34dc4fc20574c1bfa20a.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/34dc4fc20574c1bfa20a.js.)
    ~/_nuxt/369e6259a0c48e2db803.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/369e6259a0c48e2db803.js.)
    ~/_nuxt/3cca824befe55b2c8bfc.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/3cca824befe55b2c8bfc.js.)
    ~/_nuxt/59fe6cefafacf6bdeb6e.js (sourcemap at 59fe6cefafacf6bdeb6e.js.map)
    ~/_nuxt/5cd59dd492f049d3d037.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/5cd59dd492f049d3d037.js.)
    ~/_nuxt/7395d8811ae75504df41.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/7395d8811ae75504df41.js.)
    ~/_nuxt/8b963571817bd2ed580d.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/8b963571817bd2ed580d.js.)
    ~/_nuxt/8e6982091a6fcf882572.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/8e6982091a6fcf882572.js.)
    ~/_nuxt/91544dbc005f89915aae.js (sourcemap at 91544dbc005f89915aae.js.map)
    ~/_nuxt/9a087d2e91533c5532a3.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/9a087d2e91533c5532a3.js.)
    ~/_nuxt/9eee26b1bdee659976c7.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/9eee26b1bdee659976c7.js.)
    ~/_nuxt/a97b3d63544ecdea7a3a.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/a97b3d63544ecdea7a3a.js.)
    ~/_nuxt/b0b069eaaf0092a4a2c6.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/b0b069eaaf0092a4a2c6.js.)
    ~/_nuxt/c55db8b0dc9d6c32ab77.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/c55db8b0dc9d6c32ab77.js.)
    ~/_nuxt/e93b62a3fabb69186f75.js (no sourcemap ref)
      - warning: could not determine a source map reference (Could not auto-detect referenced sourcemap for ~/_nuxt/e93b62a3fabb69186f75.js.)
    ~/_nuxt/fbdfd8074483cd644e1d.js (no sourcemap ref)

It seems strange that some of .js files don't have counterpart .map files.
Do you come up with the reason?

gogoge

gogoge posted a new question

sentry-module •

Sentry Logger [Error]: Vue integration has tracing enabled, but Tracing integration is not configured

hi,
I am using Nuxt and Sentry module with my self-hosted sentry server,
when I follow the document to set up the nuxt config and enable the debug option,
I got the error message above in the title,

I have no idea how could I config the Vue integration, I think this has been done by sentry-module

this is my nuxt config

  sentry: {
    dsn: 'https://[email protected]/8', // self-hosted sentry dsn
    config: {
      debug: true,
    }, // Additional config
  },

Could anyone help me fix this issue, thanks.

ddett

ddett posted a new question

sentry-module •

wrong environment tag

our environment tags are not set correctly.
we have two environments, test and prod, implemented as stages in a heroku pipeline. for each of those stages we set process.env.ENV accordingly.

the majority of issues that should be tagged as "prod" are tagged as "test". we know which issues originate from which environment by looking at the url tag. it either starts with https://test.xxx or https://app.xxx. so we can identify the problem by seeing the test and https://app.xxx tags on the same issue.

It also looks like our problem only occurs with issues that originate from the client.

this is our nuxt.config.js:

sentry: {
config: {
environment: process.env.ENV,
release: packageJson.version + ' ' + process.env.HEROKUSLUGCOMMIT,
dsn: process.env.SENTRYDSN, }, webpackConfig: { setCommits: { repo: 'xxx/xxx', commit: process.env.HEROKUSLUGCOMMIT, auto: false, }, }, dsn: process.env.SENTRYDSN,
publishRelease: true,
},

any help is much appreciated.

njbarrett

njbarrett posted a new question

sentry-module •

Setting a custom handleError

Hello, I've looked through the docs and I can't work out where the best place to add my own custom handleError function would be?

iliyaZelenko

iliyaZelenko posted a new feature request

sentry-module •

idea Fix stacktrace and source maps for servedside

What problem does this feature solve?

It will not be necessary to use $sentry.captureException(error) to catch an error everywhere as described here, each error will be logged itself if it appears in asyncData.

What does the proposed changes look like?

I want the error to be caught through this module, for example, in this code:

async asyncData ({ params }) {
  if (params.id === '123') throw Error('Test error')

  someFunctionThatCanThrowError()
}

That is, not to write like this:

async asyncData ({ params }) {
  if (params.id === '123') {
    $sentry.captureException(Error('Test error'))
  }

  try {
    someFunctionThatCanThrowError()
  } catch (e) {
    $sentry.captureException(e)
  }
}
ValdoGhafoor

ValdoGhafoor posted a new question

sentry-module •

How to configure release publishing right ?

Hi,
I wanted to use the plugin but as I'm not used to Sentry, there are few things that I don't get from the doc of this module.
In the options, there is a "config" Object, containing by default the "environment" key.
Is this the default Sentry config that is used in Sentry.init function ?

If so, why are some options out of this object, like dsn for exemple ?

Thank you in advance for your time

sajadhsm

sajadhsm posted a new feature request

sentry-module •

idea Allow overriding webpack plugin urlPrefix

What problem does this feature solve?

If build.publicPath is pointing to a CDN, then the urlPrefix is not correct. Being able to override it, is necessary in this situation.

What does the proposed changes look like?

Maybe a quick fix would be:

if (!options.webpackConfig.urlPrefix) {
    const publicPath = posix.join(this.options.router.base, this.options.build.publicPath)
    options.webpackConfig.urlPrefix = publicPath.startsWith('/') ? `~${publicPath}` : publicPath
}

or setting the urlPrefix before merging the options.

I can submit a PR if the solution is OK.

emaadali

emaadali posted a new question

sentry-module •

How can I use the beforeSend hook?

I am trying to show the user feedback screen on a bug as described here: https://docs.sentry.io/enriching-error-data/user-feedback/?platform=browser but I don't know where to put the beforeSend hook.

brokenthorn

brokenthorn posted a new bug report

sentry-module •

bug import '@nuxtjs/sentry' causes failure to compile

Version

v4.0.1

Reproduction link

https://codesandbox.io/s/aged-frog-vsgpy?file=/pages/index.vue

Steps to reproduce

  1. Creat an empty NuxtJS project using the latest version.
  2. Add @nuxtjs/sentry to dependencies.
  3. Add @nuxtjs/sentry to nuxt.config.js modules section.
  4. $sentry is not available on the Nuxt context automatically so try to import definitions by adding import '@nuxtjs/sentry' to a Nuxt page/component.
  5. With line added at 4., build fails. Without it it works but build warns about undefined $sentry (just a type check, the object is in fact there).

What is expected ?

Successful build.

What is actually happening?

× Client
Compiled with some errors in 4.93s

√ Server
Compiled successfully in 2.97s

i Type checking in progress… nuxt:typescript 05:55:31

ERROR Failed to compile with 7 errors friendly-errors 05:55:31

These dependencies were not found: friendly-errors 05:55:31
friendly-errors 05:55:31

  • childprocess in ./nodemodules/@sentry/cli/js/helper.js friendly-errors 05:55:31
  • console in ./node_modules/@sentry/node/esm/integrations/console.js friendly-errors 05:55:31
  • fs in ./nodemodules/@sentry/node/esm/parsers.js, ./nodemodules/@sentry/node/esm/integrations/modules.js and 1 other friendly-errors 05:55:31
  • net in ./node_modules/https-proxy-agent/index.js friendly-errors 05:55:31
  • tls in ./nodemodules/https-proxy-agent/index.js friendly-errors 05:55:31 friendly-errors 05:55:31 To install them, you can run: npm install --save childprocess console fs net tls friendly-errors 05:55:31
    i Waiting for file changes 05:55:31
    {"level":30,"time":1587351331741,"pid":16248,"hostname":"baby","msg":"Server listening at http://0.0.0.0:3001","v":1}

Additional comments?

Developing on Windows 10.