Questions tagged [stacktrace.js]

Framework-agnostic, micro-library for getting stack traces in all web browsers.

About

stacktrace.js uses browsers' Error.stack mechanism to generate stack traces, parses them, enhances them with source maps and uses Promises to return an Array of StackFrames.

Links

16 questions
16
votes
1 answer

Simplest way to catch JS errors

I've been doing some research into how we can catch JavaScript errors, and then send them off to our own system for internal logging (so we can try and replicate where possible, and fix any possible bugs). So far I have found quite a few paid…
Andrew Newby
  • 4,197
  • 2
  • 29
  • 59
6
votes
1 answer

Using StackTrace.js with Angular.js

I'm implementing a logger for my whole MEAN.js project. I have a server side logger that works well, and I've set an endpoint to receive a POST request with an exception to log a client error. I'm using StackTrace.js for client side error logging,…
4
votes
1 answer

Angular 2+ Path in ErrorHandler error.stack

I'm trying to use stacktrace.js to report errors, but the path in the stack trace is referencing "ng:///FormModule/MyComponent.ngfactory.js" TypeError: Cannot read property 'push' of undefined at Object.eval [as handleEvent]…
Ulfius
  • 439
  • 4
  • 12
3
votes
0 answers

What's a good snippet to safely instrument "almost all functions" using stacktrace.js?

stacktrace.js is a micro-library for getting stack traces in all web browsers. It offers functions instrumentation: var p = new printStackTrace.implementation(); p.instrumentFunction(this, 'baz', logStackTrace); function logStackTrace(stack) { …
ripper234
  • 202,011
  • 255
  • 600
  • 878
3
votes
3 answers

Make the new stacktrace.js library synchronous

I am using the new stacktracejs libary and it returns a promise. StackTrace.get() // this results in a promise Is there something I can do to make it synchronous? like this: var result = magicalSomething(StackTrace.get());
dtracers
  • 1,336
  • 2
  • 13
  • 31
3
votes
0 answers

Webpack umd seemingly breaks stacktrace-js functionality

We're trying to use stacktrace-js with the awesome logary-js (my project) but after going through webpack it would seem it doesn't work anymore. Here's the configuration for webpack…
Henrik
  • 9,303
  • 4
  • 49
  • 83
3
votes
1 answer

ReferenceError: printStackTrace is not defined

I get the following error "ReferenceError: printStackTrace is not defined", when I tried to use StackTrace in my angular aplication.
Peter
  • 55
  • 5
2
votes
1 answer

Javascript : Error position evaluating a JS Function('...my code as string')

We've some user defined fields defining javascript functions and would like to show the user the position ( line, column ) when an error is thrown. For example : userFunc = new Function('context', '{ let a = 0; \n context.missingFunction(); return…
ic3
  • 7,231
  • 8
  • 55
  • 101
2
votes
0 answers

Module not found: Error: Can't resolve 'stacktrace-js' in ionic3

When I am trying to get the stacktrace via stacktrace-js, I get this error: Module not found: Error: Can't resolve 'stacktrace-js' in ionic3 Please help me. My Ionic Info: @ionic/cli-plugin-proxy : 1.5.7 @ionic/cli-utils : 1.19.1 ionic…
ram kumar
  • 31
  • 4
2
votes
1 answer

How to get stacktracejs working with requirejs amd modules

Library: Library repo that im using I just don't think I am getting the point of requirejs that leads me to be incapable of loading in StackTrace from the stacktrace js library. I have stacktrace-with-promises-and-json-polyfills.min.js saved under…
lzc
  • 1,371
  • 5
  • 21
  • 37
1
vote
1 answer

Getting context from map files

I use stacktrace.js to get the correct stack trace on exception but I wonder if it’s possible to extract part of the code to get the context of where the exception has arisen Is there any good and simple way to do that ?
Dragouf
  • 4,500
  • 4
  • 41
  • 51
1
vote
0 answers

StackTrace-GPS looking for nonexistent file when error is inside a bundled JS file

I'm trying to use StackTrace and StackTraceGPS to extract code error locations, however, when an error occurs inside a a bundled file, it tries to retrieve a non-existent file. For example my vendors.min.js is just a combined and minifed file of…
Amir
  • 2,546
  • 3
  • 18
  • 32
1
vote
1 answer

ExtJs and StackTrace.js

I try to include StackTrace.js in my app but It didn't work. I try with CDN putting : in my index.html But I have the…
Psycho
  • 381
  • 1
  • 17
0
votes
1 answer

How to get error source file from firebase crashlytics stack trace text index.android.bundle or iOS main.jsbundle?

How to get the source file line and column information from a crashlytics stack trace line pointing to index.android.bundle:474:6500? A crashlytics report stack trace text looks similar to: Non-fatal Exception:…
Ed of the Mountain
  • 4,137
  • 3
  • 37
  • 49
0
votes
1 answer

How can I get readable stacktrace while using webpack? Tried stacktrace.js

I am using webpack with "devtool: nosources-source-map" in order to create a bundle that includes my javascript codes. But I also need to log the stack trace when an error occures. I need to log trace as it shows on browser console: But in the end…
Mesut Can
  • 173
  • 3
  • 16
1
2