sourceURLs with webpack:/// interfere with window.onerror reporting
Reported by
savvopou...@gmail.com,
Sep 16 2017
|
||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.0.3112.113 Safari/537.36 Steps to reproduce the problem: See also: https://github.com/webpack/webpack/issues/5681#issuecomment-329957675 https://github.com/savvopoulos/webpack-on-error Note that you need an HTTP server in order to properly repro the issue; file:/// seems to come with its own rules; http server included, needs python3. Build: ./build.sh (this will run, among other things, webpack, which generates sourceURLs) Run: ./serve.py Go to: http://localhost:8000/index.html - error looks good Now go to: http://localhost:8000/dist/index.html - Script Error. :-( What is the expected behavior? Since the script comes from the same host, I would have expected error reporting to work. What went wrong? I think Chrome gets confused about the ownership of the script, because of the webpack:/// scheme in the sourceURLs. But the originally script came from the same host, and Chrome should arguably know better. Did this work before? N/A Chrome version: 60.0.3112.113 Channel: n/a OS Version: OS X 10.12.6 Flash Version:
,
Sep 16 2017
I pushed a branch that includes the dist/ folder, here: https://github.com/savvopoulos/webpack-on-error/tree/with_dist
,
Sep 19 2017
I'd guess this is an issue of webpack itself, for transforming any internal URLs. What Blink or Chrome can help here?
,
Sep 19 2017
I can repro this however I don't know why the Error being thrown is a script error. Works correctly in Safari. Perhaps someone from the V8 team can have a look.
,
Sep 19 2017
@kochi It seems to me that window.error should be receiving full errors, of a script is from the same origin, regardless of sourceURL "origins".
,
Sep 19 2017
Thank you for providing more feedback. Adding requester "kochi@chromium.org" to the cc list and removing "Needs-Feedback" label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Sep 21 2017
Requesting some one from the V8 team for help in further triaging of this issue.
,
Sep 25 2017
Yang, can you please evaluate that?
,
Oct 2
The issue and reproduction case described above no longer occurs in Chrome Canary 71.0.3567.0 Can someone from the Chrome team confirm that this issue has been resolved and what version it was fixed in? |
||||||
►
Sign in to add a comment |
||||||
Comment 1 by savvopou...@gmail.com
, Sep 16 2017