Skip to content

RegEx in tracingOrigins config breaks ember build #5903

Closed
@dagroe

Description

@dagroe

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which package are you using?

@sentry/ember

SDK Version

7.14.1

Framework Version

ember 4.7.0

Link to Sentry event

No response

Steps to Reproduce

  1. Create new app using ember-cli 4.7.0 ember new ember-quickstart --lang en
  2. install sentry SDK ember install @sentry/ember
  3. add config to config/environment.js, make sure to include RegEx in tracingOrigins, e.g.
  ENV['@sentry/ember'] = {
    sentry: {
      tracesSampleRate: 1.0,
      debug: false,
      browserTracingOptions: {
        tracingOrigins: [
          'localhost',
          /^\//,
        ],
      },
    },
  };
  1. run ember ember serve

Expected Result

ember builds and runs app

Actual Result

build fails with error

non serializable item found in config: /^\//
[Embroider:MacrosConfig] the given config from '/YOUR_PATH/node_modules/@sentry/ember' for packageName 'undefined' is not JSON serializable.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions