v8/test/inspector/debugger/script-on-after-compile-expected.txt
Sigurd Schneider 83d7c4d34b Report reliable embedderName in scriptParsed/scriptFailedToParse
Currently, only a scriptURL is reported, which can be over-written by
sourceURL comments of the script. This means a script can basically
claim to come from anywhere. This means that DevTools doesn't know the
resource name the embedder provided if there is a sourceURL comment.
This CL adds a `embedderName` field to the scriptParsed and
scriptFailedToParse events that reports the name the embedder
associated with the script.

Bug: chromium:974543
Change-Id: I9863f878f57638174847890d9a3818952b1efc27
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2317310
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69078}
2020-07-27 15:40:00 +00:00

852 lines
19 KiB
Plaintext

Checks that inspector correctly process compiled scripts
scriptParsed
{
scriptSource : function foo1(){}//# sourceURL=oneline.js<nl>
}
{
embedderName :
endColumn : 0
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 1912c266357e416d5e19323209ce6b851f2e0f2c
isLiveEdit : false
isModule : false
length : 42
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : oneline.js
}
scriptParsed
{
scriptSource : function foo2(){}//# sourceURL=oneline-without-nl.js
}
{
embedderName :
endColumn : 52
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : true
hash : 10f9f2639b93aaa6175107400af8e91f3b0f471b
isLiveEdit : false
isModule : false
length : 52
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : oneline-without-nl.js
}
scriptParsed
{
scriptSource : function foo3(){}<nl>//# sourceURL=twoline.js<nl>
}
{
embedderName :
endColumn : 0
endLine : 2
executionContextId : <executionContextId>
hasSourceURL : true
hash : 0f8af679a498b4814efa01b934ce49ca06bf4ee7
isLiveEdit : false
isModule : false
length : 43
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : twoline.js
}
scriptParsed
{
scriptSource : function foo4(){}<nl><nl>//# sourceURL=threeline.js<nl>
}
{
embedderName :
endColumn : 0
endLine : 3
executionContextId : <executionContextId>
hasSourceURL : true
hash : 2cc1f4f316e466c0110dc50790dd520e45de6763
isLiveEdit : false
isModule : false
length : 46
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : threeline.js
}
scriptParsed
{
scriptSource : function foo5(){}//# sourceMappingURL=oneline-map<nl>
}
{
embedderName :
endColumn : 0
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : false
hash : 127829554266b55666f9cf02c2c7a05463c8c723
isLiveEdit : false
isModule : false
length : 50
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : oneline-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo6(){}//# sourceMappingURL=oneline-without-nl-map
}
{
embedderName :
endColumn : 60
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : false
hash : 1385e0fc24082a91521585943bfcce52262a7f4b
isLiveEdit : false
isModule : false
length : 60
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : oneline-without-nl-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo7(){}<nl>//# sourceMappingURL=twoline-map<nl>
}
{
embedderName :
endColumn : 0
endLine : 2
executionContextId : <executionContextId>
hasSourceURL : false
hash : 2b15af1d4127ae68644e0ce4443021185dbe2d2f
isLiveEdit : false
isModule : false
length : 51
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : twoline-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo8(){}<nl><nl>//# sourceMappingURL=threeline-map<nl>
}
{
embedderName :
endColumn : 0
endLine : 3
executionContextId : <executionContextId>
hasSourceURL : false
hash : 0036aba78093d0cf2ee6350c84b06ffe53aff63e
isLiveEdit : false
isModule : false
length : 54
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : threeline-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo9(){}//# sourceMappingURL=source-mapping-url-map<nl>//# sourceURL=source-url.js
}
{
embedderName :
endColumn : 27
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 374ed6be308871fa14f434e504168cba446836db
isLiveEdit : false
isModule : false
length : 88
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : source-mapping-url-map
startColumn : 0
startLine : 0
url : source-url.js
}
scriptParsed
{
scriptSource : function foo10(){}//# sourceURL=source-url.js<nl>//# sourceMappingURL=source-mapping-url-map
}
{
embedderName :
endColumn : 43
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 0db017360f0b77f12660e00ca287b54b602a6795
isLiveEdit : false
isModule : false
length : 89
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : source-mapping-url-map
startColumn : 0
startLine : 0
url : source-url.js
}
scriptParsed
{
scriptSource : function foo11(){}<nl>//# sourceURL=end1.js
}
{
embedderName :
endColumn : 21
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 096615cf17450c8153564f8c77c9b0421927e011
isLiveEdit : false
isModule : false
length : 40
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : end1.js
}
scriptParsed
{
scriptSource : function foo12(){}<nl>//# sourceURL=end2.js
}
{
embedderName :
endColumn : 22
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 1314f0ef0397feb553564f8c405d35f91927e011
isLiveEdit : false
isModule : false
length : 41
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : end2.js
}
scriptParsed
{
scriptSource : function foo13(){}
}
{
embedderName :
endColumn : 18
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : false
hash : 033b33d18f0514168154be7f45f542e4811403e2
isLiveEdit : false
isModule : false
length : 18
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo15(){}; eval("function foo14(){}//# sourceURL=eval.js")//# sourceURL=eval-wrapper.js
}
{
embedderName :
endColumn : 96
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : true
hash : 01fcc474486991b12de451e963f458f0767397c8
isLiveEdit : false
isModule : false
length : 96
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : eval-wrapper.js
}
scriptParsed
{
scriptSource : function foo14(){}//# sourceURL=eval.js
}
{
embedderName :
endColumn : 39
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : true
hash : 06c3a0dd6160579b49d51af109a969910e2e33fd
isLiveEdit : false
isModule : false
length : 39
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : eval.js
}
scriptParsed
{
scriptSource : function foo16(){}<nl>
}
{
embedderName :
endColumn : 0
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : false
hash : 033b33d125db477a8154be7f45f542e4518bf49c
isLiveEdit : false
isModule : false
length : 19
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo17(){}<nl><nl>
}
{
embedderName :
endColumn : 0
endLine : 2
executionContextId : <executionContextId>
hasSourceURL : false
hash : 033b33d1122e39ae8154be7f45f542e438020797
isLiveEdit : false
isModule : false
length : 20
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo18(){}<nl><nl><nl>
}
{
embedderName :
endColumn : 0
endLine : 3
executionContextId : <executionContextId>
hasSourceURL : false
hash : 37189768928f28958154be7f45f542e438020797
isLiveEdit : false
isModule : false
length : 21
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo19(){}<nl><nl><nl><nl>
}
{
embedderName :
endColumn : 0
endLine : 4
executionContextId : <executionContextId>
hasSourceURL : false
hash : 1886d59067d0c92d8154be7f45f542e438020797
isLiveEdit : false
isModule : false
length : 22
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo1(){}//# sourceURL=oneline.js<nl>
}
{
embedderName :
endColumn : 0
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 1912c266357e416d5e19323209ce6b851f2e0f2c
isLiveEdit : false
isModule : false
length : 42
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : oneline.js
}
scriptParsed
{
scriptSource : function foo2(){}//# sourceURL=oneline-without-nl.js
}
{
embedderName :
endColumn : 52
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : true
hash : 10f9f2639b93aaa6175107400af8e91f3b0f471b
isLiveEdit : false
isModule : false
length : 52
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : oneline-without-nl.js
}
scriptParsed
{
scriptSource : function foo3(){}<nl>//# sourceURL=twoline.js<nl>
}
{
embedderName :
endColumn : 0
endLine : 2
executionContextId : <executionContextId>
hasSourceURL : true
hash : 0f8af679a498b4814efa01b934ce49ca06bf4ee7
isLiveEdit : false
isModule : false
length : 43
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : twoline.js
}
scriptParsed
{
scriptSource : function foo4(){}<nl><nl>//# sourceURL=threeline.js<nl>
}
{
embedderName :
endColumn : 0
endLine : 3
executionContextId : <executionContextId>
hasSourceURL : true
hash : 2cc1f4f316e466c0110dc50790dd520e45de6763
isLiveEdit : false
isModule : false
length : 46
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : threeline.js
}
scriptParsed
{
scriptSource : function foo5(){}//# sourceMappingURL=oneline-map<nl>
}
{
embedderName :
endColumn : 0
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : false
hash : 127829554266b55666f9cf02c2c7a05463c8c723
isLiveEdit : false
isModule : false
length : 50
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : oneline-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo6(){}//# sourceMappingURL=oneline-without-nl-map
}
{
embedderName :
endColumn : 60
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : false
hash : 1385e0fc24082a91521585943bfcce52262a7f4b
isLiveEdit : false
isModule : false
length : 60
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : oneline-without-nl-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo7(){}<nl>//# sourceMappingURL=twoline-map<nl>
}
{
embedderName :
endColumn : 0
endLine : 2
executionContextId : <executionContextId>
hasSourceURL : false
hash : 2b15af1d4127ae68644e0ce4443021185dbe2d2f
isLiveEdit : false
isModule : false
length : 51
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : twoline-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo8(){}<nl><nl>//# sourceMappingURL=threeline-map<nl>
}
{
embedderName :
endColumn : 0
endLine : 3
executionContextId : <executionContextId>
hasSourceURL : false
hash : 0036aba78093d0cf2ee6350c84b06ffe53aff63e
isLiveEdit : false
isModule : false
length : 54
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : threeline-map
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo9(){}//# sourceMappingURL=source-mapping-url-map<nl>//# sourceURL=source-url.js
}
{
embedderName :
endColumn : 27
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 374ed6be308871fa14f434e504168cba446836db
isLiveEdit : false
isModule : false
length : 88
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : source-mapping-url-map
startColumn : 0
startLine : 0
url : source-url.js
}
scriptParsed
{
scriptSource : function foo10(){}//# sourceURL=source-url.js<nl>//# sourceMappingURL=source-mapping-url-map
}
{
embedderName :
endColumn : 43
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 0db017360f0b77f12660e00ca287b54b602a6795
isLiveEdit : false
isModule : false
length : 89
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : source-mapping-url-map
startColumn : 0
startLine : 0
url : source-url.js
}
scriptParsed
{
scriptSource : function foo11(){}<nl>//# sourceURL=end1.js
}
{
embedderName :
endColumn : 21
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 096615cf17450c8153564f8c77c9b0421927e011
isLiveEdit : false
isModule : false
length : 40
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : end1.js
}
scriptParsed
{
scriptSource : function foo12(){}<nl>//# sourceURL=end2.js
}
{
embedderName :
endColumn : 22
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 1314f0ef0397feb553564f8c405d35f91927e011
isLiveEdit : false
isModule : false
length : 41
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : end2.js
}
scriptParsed
{
scriptSource : function foo13(){}
}
{
embedderName :
endColumn : 18
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : false
hash : 033b33d18f0514168154be7f45f542e4811403e2
isLiveEdit : false
isModule : false
length : 18
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo15(){}; eval("function foo14(){}//# sourceURL=eval.js")//# sourceURL=eval-wrapper.js
}
{
embedderName :
endColumn : 96
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : true
hash : 01fcc474486991b12de451e963f458f0767397c8
isLiveEdit : false
isModule : false
length : 96
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : eval-wrapper.js
}
scriptParsed
{
scriptSource : function foo14(){}//# sourceURL=eval.js
}
{
embedderName :
endColumn : 39
endLine : 0
executionContextId : <executionContextId>
hasSourceURL : true
hash : 06c3a0dd6160579b49d51af109a969910e2e33fd
isLiveEdit : false
isModule : false
length : 39
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
stackTrace : {
callFrames : [
[0] : {
columnNumber : 20
functionName :
lineNumber : 0
scriptId : <scriptId>
url : eval-wrapper.js
}
]
}
startColumn : 0
startLine : 0
url : eval.js
}
scriptFailedToParse
{
scriptSource : {a:2:<nl>//# sourceURL=http://a.js
}
{
embedderName :
endColumn : 25
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 33c5612558c02e5a3bfa0d098c82865f38f98df2
isModule : false
length : 31
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url : http://a.js
}
scriptFailedToParse
{
scriptSource : }//# sourceURL=failed.js<nl>//# sourceMappingURL=failed-map
}
{
embedderName :
endColumn : 31
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : true
hash : 01ee31bb2ab335516427f7ff73ddc9d476adbab4
isModule : false
length : 56
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL : failed-map
startColumn : 0
startLine : 0
url : failed.js
}
scriptParsed
{
scriptSource : function foo16(){}<nl>
}
{
embedderName :
endColumn : 0
endLine : 1
executionContextId : <executionContextId>
hasSourceURL : false
hash : 033b33d125db477a8154be7f45f542e4518bf49c
isLiveEdit : false
isModule : false
length : 19
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo17(){}<nl><nl>
}
{
embedderName :
endColumn : 0
endLine : 2
executionContextId : <executionContextId>
hasSourceURL : false
hash : 033b33d1122e39ae8154be7f45f542e438020797
isLiveEdit : false
isModule : false
length : 20
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo18(){}<nl><nl><nl>
}
{
embedderName :
endColumn : 0
endLine : 3
executionContextId : <executionContextId>
hasSourceURL : false
hash : 37189768928f28958154be7f45f542e438020797
isLiveEdit : false
isModule : false
length : 21
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
scriptParsed
{
scriptSource : function foo19(){}<nl><nl><nl><nl>
}
{
embedderName :
endColumn : 0
endLine : 4
executionContextId : <executionContextId>
hasSourceURL : false
hash : 1886d59067d0c92d8154be7f45f542e438020797
isLiveEdit : false
isModule : false
length : 22
scriptId : <scriptId>
scriptLanguage : JavaScript
sourceMapURL :
startColumn : 0
startLine : 0
url :
}
Remove script references and re-enable debugger.