FR: Global error catcher for specific methods?
Reported by
moni...@gmail.com,
Dec 16 2016
|
||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36 Steps to reproduce the problem: I have an app written in Angular 2 (with heavy usage of Observables), that is spitting out errors like "Cannot read property 'map' of null". The error stack is useless as it points to internal angular code and says nothing about the origin of the error. In my app code there's like 150 ocurrences of `.map`. This would be the last thing I would like to do - to go and inspect each and every of them. What is the expected behavior? What went wrong? So I was wondering if we could have something like a global listener per invoked 'method' that could allow me - in this particular case - to pin down which of the arrays exactly is null and causing the problem, in which js/ts file (using sourceMap if provided) Did this work before? N/A Chrome version: 54.0.2840.98 Channel: n/a OS Version: OS X 10.11.6 Flash Version: Shockwave Flash 24.0 r0 Let's put aside discussion about using try/catches and defensive programming in one's code. Sometimes you just have to debug what you have on your table :)
,
Dec 16 2016
Well, first off, thank you for a thoughtful reply. Blackboxing should definitely make my console cleaner, I will try the Pausing on Monday.
,
Dec 17 2016
|
||
►
Sign in to add a comment |
||
Comment 1 by chenwilliam@chromium.org
, Dec 16 2016