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

Getting error messages of the format not_specified at e.sendExceptionInternal #1006

Closed
mohamedfasil opened this issue Aug 19, 2019 · 9 comments

Comments

@mohamedfasil
Copy link

Application insights is reporting exceptions with following message
problemId: not_specified at e.sendExceptionInternal
details:

[{"outerId":"0","message":"not_specified","type":"Error","id":"0","parsedStack":[{"assembly":"at e.sendExceptionInternal
(https://domain.com/static/js/main.78bf8648.js:1:124888)","method":"e.sendExceptionInternal","level":0,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at e.trackException
(https://domain.com/static/js/main.78bf8648.js:1:125105)","method":"e.trackException","level":1,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at e.trackException
(https://domain.com/static/js/main.78bf8648.js:1:185603)","method":"e.trackException","level":2,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at
Function.e.trackException (https://domain.com/static/js/main.78bf8648.js:1:188348)","method":"Function.e.trackException","level":3,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at https://domain.com/static/js/main.78bf8648.js:1:66103","method":"<no_method>","level":4,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"}],"rawStack":"Error: not_specified\n at e.sendExceptionInternal (https://domain.com/static/js/main.78bf8648.js:1:124888)\n at e.trackException (https://domain.com/static/js/main.78bf8648.js:1:125105)\n at e.trackException (https://domain.com/static/js/main.78bf8648.js:1:185603)\n at Function.e.trackException (https://domain.com/static/js/main.78bf8648.js:1:188348)\n at https://domain.com/static/js/main.78bf8648.js:1:66103"}]

AppInsights Js version "@microsoft/applicationinsights-web": "^2.1.1",

Please help me in understanding what's this issue

@markwolff
Copy link
Contributor

Is this error occurring passively or when you make a manual call to trackException? If so, could you post this call? Else could you post how you are initializing the SDK?

@mohamedfasil
Copy link
Author

@markwolff it seems like happening on trackException
I'm initializing appinsights like this

    const appInsights = new ApplicationInsights({
      config: {
        instrumentationKey: config.instrumentationKey,
        enableCorsCorrelation: true,
        disableCorrelationHeaders: false,
        correlationHeaderExcludedDomains: config.THIRD_PARTY_DOMAINS
      }
    });
    appInsights.loadAppInsights();
    appInsights.addTelemetryInitializer(telemetryItem => {
      telemetryItem.tags['ai.cloud.role'] = 'UI';
    })

We've our own console implementation, where console.error argument is send to appinsights.trackException, some of those arguments are just strings, that could be the problem

@mohamedfasil
Copy link
Author

We've fixed that problem, we're sending errors as

     if (error instanceof Error) {
       appInsights.trackException({
          exception: error
        });
      } else {
       appInsights.trackException({
          exception: new Error(error)
        });
      }

But still receiving the same error

not_specified at e.sendExceptionInternal
client_Browser	Chrome 76.0
client_OS	Mac OS X 10.13
operation_Id	k9frJ
details	[{"outerId":"0","message":"not_specified","type":"Error","parsedStack":[{"assembly":"at e.sendExceptionInternal (https://domain.com/static/js/main.78bf8648.js:1:124888)","method":"e.sendExceptionInternal","level":0,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at e.trackException (https://domain.com/static/js/main.78bf8648.js:1:125105)","method":"e.trackException","level":1,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at e.trackException (https://domain.com/static/js/main.78bf8648.js:1:185603)","method":"e.trackException","level":2,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at Function.e.trackException (https://domain.com/static/js/main.78bf8648.js:1:188348)","method":"Function.e.trackException","level":3,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"},{"assembly":"at https://domain.com/static/js/main.78bf8648.js:1:66103","method":"<no_method>","level":4,"line":1,"fileName":"https://domain.com/static/js/main.78bf8648.js"}],"id":"0","rawStack":"Error: not_specified\n at e.sendExceptionInternal (https://domain.com/static/js/main.78bf8648.js:1:124888)\n at e.trackException (https://domain.com/static/js/main.78bf8648.js:1:125105)\n at e.trackException (https://domain.com/static/js/main.78bf8648.js:1:185603)\n at Function.e.trackException (https://domain.com/static/js/main.78bf8648.js:1:188348)\n at https://domain.com/static/js/main.78bf8648.js:1:66103"}]

Any help would be much appreciated

@markwolff
Copy link
Contributor

markwolff commented Aug 21, 2019

I'm unable to repro this on my end. Do you have an example which reproduces it on your end? Is this an error being shown in console or is it a problem with the telemetry?

@xiao-lix
Copy link
Contributor

It's probably because the type of the Error parameter is wrong. When you do new Error(error), is the type of error string?
image

If not, it may give you the message of not specified like this:
let error = [];
ai.trackException({ exception: new Error(error) })
then I receive:
image

@mohamedfasil
Copy link
Author

@xiao-lix that makes sense, but at the else part we're only sending strings, will double check on that and update you

@xiao-lix xiao-lix closed this as completed Sep 3, 2019
@AbhaysinghBhosale
Copy link

AbhaysinghBhosale commented Jun 2, 2020

getting the same error logged in app-insight
componentDidCatch(error, info) { let correlationId = window.appInsights.context.telemetryTrace.traceID; console.log(error,info); window.appInsights.trackException(error, null, {"info":info.componentStack,"itemType":"JavaScript"}, {}, "Error"); }
This error is not permanent but occurs at random time.

@markwolff
Copy link
Contributor

@AbhaysinghBhosale please see API documentation here

window.appInsights.trackException({
  exception: error,
  properties: {"info":info.componentStack,"itemType":"JavaScript"}
});

@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants