You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Wanted to ask if there's any way for extension to report exceptions in a way that they can be recognized as errors by the Application Insights.
Currently, all errors are reported as events with unhandlederror name. This makes them impossible to properly aggregate and identify issues as they fall under a single category and the important details like stack traces can be extracted for individual records only making it difficult to see what type of errors occur at what frequency.
In ApplicationInsights-JS package, there's a trackException method which seem to work ok. However, using that package in my vscode extension seem very unstable as I get a tons of errors about retries and other stuff. I dig a bit into the source code of that package, and tried to replicate its behavior when sending exceptions, specifically in appInsightsClientFactory I tried to add logException method that'd construct an event that would match what the JS module seem to generate:
With this approach, errors are now recognized and reported under "Failure" in Application Insights, however, they still don't have the correct shape and the data seem to just be serialized to JSON and put as description while stack trace doesn't get extracted properly:
I was wondering if there's a better way this can be done such that we can rely on Application Insights in our extension for error tracking,
The text was updated successfully, but these errors were encountered:
You can query app insights for the unhandled errors but I know it's not as nice as this exception UI. A lot of the reason we do error reporting in a non-standard way is so that we may clean the error stack of any possible PII such as usernames as to not identify any of the users. I'm not familiar with how to change things such that this view is populated.
Thanks for maintaining this package!
Wanted to ask if there's any way for extension to report exceptions in a way that they can be recognized as errors by the Application Insights.
Currently, all errors are reported as events with
unhandlederror
name. This makes them impossible to properly aggregate and identify issues as they fall under a single category and the important details like stack traces can be extracted for individual records only making it difficult to see what type of errors occur at what frequency.In ApplicationInsights-JS package, there's a trackException method which seem to work ok. However, using that package in my vscode extension seem very unstable as I get a tons of errors about retries and other stuff. I dig a bit into the source code of that package, and tried to replicate its behavior when sending exceptions, specifically in
appInsightsClientFactory
I tried to add logException method that'd construct an event that would match what the JS module seem to generate:With this approach, errors are now recognized and reported under "Failure" in Application Insights, however, they still don't have the correct shape and the data seem to just be serialized to JSON and put as description while stack trace doesn't get extracted properly:
I was wondering if there's a better way this can be done such that we can rely on Application Insights in our extension for error tracking,
The text was updated successfully, but these errors were encountered: