Closed Bug 764600 Opened 13 years ago Closed 13 years ago

Send front-end errors to lattice

Categories

(Pancake Graveyard :: Front-end, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: oyiptong, Assigned: sfoster)

References

Details

Send JS errors to the back-end for archival Format can be seen here: https://github.com/lincolnloop/raven-js/blob/develop/src/raven.js Roughly: [ { "message": label, "culprit": fileurl, "stacktrace": stacktrace, "exception": { "type": type, "value": message }, "site": site, "timestamp": timestamp, } ] A stacktrace looks like that: stacktrace = { "frames": [{ "filename": fileurl, "lineno": lineno }] };
Assignee: nobody → sfoster
Blocks: 764601
Fixed with merge of error-logging branch and later fixes: https://bitbucket.org/mozillapancake/pancake/changeset/01214cf5bf8b ..to.. https://bitbucket.org/mozillapancake/pancake/changeset/ff90f8e2a740 This adds new logging architecture, exception and stacktrace preparation in lib/errors and a lib/logger/remoteexceptions module which packages the data up and sends to /lattice/exceptions Also, when web.json has web.is_debug: true, you'll get a debug/dev toolbar rendered by root.mustache ('/'). Just hover/click the top of the page to show it, and to load the spec runners to run our unit tests. See sample output of the remote exception logger, e.g.: http://play.fxhome.mozillalabs.com:9000/default/group/22/ There is more work to do on the stacktraces. When we catch thrown exceptions using window.onerror, we don't get a useful stacktrace. This needs to be fixed at the source of the error (the view, model/collection or controller) and handled/propogated correctly rather than left uncaught. That's a not-insignificant amount of work and worthy of its own ticket.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
I've been doing 2 things: 1) intercept a lattice response with Charles or similar debugging proxy and break the JSON by either changing the name of a key, or triggering a parse error by removing a '}' 2) In the code (e.g. placecollection.js) adding an extra required field in the parse handler. #1 is probably more feasible for you. We don't have any special trigger-error back doors :)
You need to log in before you can comment on or make changes to this bug.