browserify generated web site, can not inspect variable values, works in Chrome
Categories
(DevTools :: Debugger, defect, P3)
Tracking
(Not tracked)
People
(Reporter: tc, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:86.0) Gecko/20100101 Firefox/86.0
Steps to reproduce:
We're using what I'm fairly sure is the standard way to bundle Angular 1.x apps using Browserify under Gulp:
var files = await glob( paths.scripts );
var b = browserify({
entries: files,
debug: true,
transform: [ngAnnotate]
});
return b.bundle()
.pipe(source('app.min.js'))
.pipe(buffer())
//.pipe(cachebust.resources()) TODO should then take name, add/replace to index.html instead of cacehBustTask
.pipe(sourcemaps.init({loadMaps: true}))
.pipe(uglify())
.on('error', log.error)
.pipe(sourcemaps.write('./'))
.pipe(gulp.dest(paths.output));
Actual results:
Can set break points, but inspection of all values always undefined.
Works fine in Chrome
Expected results:
Can set break points, but inspection of all values shows actual values.
Works fine in Chrome and FireFox
Here is a minimal test case : https://github.com/tomchiverton/bugzilla-1700600
Clone it, run "npm install" and then "npm run serve"
Open the given URL.
Observe the log message.
Use CTRL-P to open app.js in the debugger and set a break point on the console.log line (line number 10).
Press F5 to refresh.
FireFox stops on line 10.
Hover over "$state" at end of line 8. Shows as undefined.
Do the same steps in Chromium, shows as a complicated object.
Comment 4•4 years ago
|
||
Thanks for reporting and the test case.
I can reproduce it.
Updated•4 years ago
|
Updated•2 years ago
|
Comment 8•1 year ago
•
|
||
Finally got some chance to look into this
This relates to map scopes been switched off. Once switched on it works (as shown in attached screenshot)
Also see https://bugzilla.mozilla.org/show_bug.cgi?id=1680228#c3
We are looking into turning map scopes on by default in Bug 1695621.
Comment 9•1 year ago
|
||
Closing this for now.
Description
•