New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 794057 link

Starred by 3 users

Issue metadata

Status: WontFix
Owner:
Closed: Dec 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 3
Type: Bug



Sign in to add a comment

eval-souce-map sourceURL does no matches page url causing cross-origin

Reported by githonie...@gmail.com, Dec 12 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.84 Safari/537.36

Steps to reproduce the problem:
1. using webpack and use eval-soucemap
2. page dev url is like 'http://localhost:8078', sourceURL is like `webpack-internal:///${module.id}\n`
3. when a uncaught promise reject throw from my js, error stack is
```
at VueComponent.queryDetail (webpack-internal:///./node_modules/babel-loader/lib/index.js!./node_modules/if-loader/index.js!./node_modules/vue-loader/lib/selector.js?type=script&index=0&bustCache!./node_modules/if-loader/index.js!./helios-view/src/commonPack/biz-detail/view/page/step1.vue:229:50)
```
Chrome's native Promise global event `onunhandledrejection` not working
4.  change webpack source to make sourceUrl like `http://localhost:8078/webpack-internal:///${module.id}\n`, `onunhandledrejection` is working well now.
error stack is
```
at VueComponent.queryDetail (http://localhost:8078/webpack-internal///./node_modules/babel-loader/lib/index.js!./node_modules/if-loader/index.js!./node_modules/vue-loader/lib/selector.js?type=script&index=0&bustCache!./node_modules/if-loader/index.js!./helios-view/src/commonPack/biz-detail/view/page/step1.vue:229:50)
```

What is the expected behavior?
ignore sourceURL to make `onunhandledrejection` work

What went wrong?
sourceURL must be the same domain with page url  to make `onunhandledrejection` work

Did this work before? No 

Chrome version: 63.0.3239.84  Channel: stable
OS Version: 10.0
Flash Version:
 
Labels: Needs-Triage-M63
This issue seems to be out of scope as it is related to code part, hence adding TE-NeedsTriageHelp for further investigation of the issue.
Cc: viswatej...@techmahindra.com sc00335...@techmahindra.com
Labels: Triaged-ET TE-NeedsTriageHelp
Components: -Platform>DevTools Platform>DevTools>JavaScript
Labels: -Pri-2 Pri-3
Owner: kozy@chromium.org
Status: Assigned (was: Unconfirmed)

Comment 5 by kozy@chromium.org, Dec 12 2017

Status: WontFix (was: Assigned)
Unfortunately we could not violate cross origin policy when report rejected promise to handler. Otherwise there is no any sense in this check - you always can add sourceURL to any script to bypass this check.

Sign in to add a comment