Debug .js file generated from .ts (only .js and .js.map available)
Categories
(DevTools :: Debugger, defect, P2)
Tracking
(Not tracked)
People
(Reporter: mtester270, Unassigned)
References
(Blocks 1 open bug, )
Details
Attachments
(3 files)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:108.0) Gecko/20100101 Firefox/108.0
Steps to reproduce:
Open web page where is only available .js & .js.map files (no .ts) and when i put breakpoint in .js file it not works ... debugger trying to go to .ts file which is not avail and got error:
Error while fetching an original source: can't assign to property "metadata" on "request failed with status 404": not an object
Source URL: <unknown>
Also try ignore .ts file but this cause no page break and loads normally.
Actual results:
break-point not hit and page breaks on that error
Expected results:
Break and step into .js file (in chrome it works normally)
Comment 1•3 years ago
|
||
The Bugbug bot thinks this bug should belong to the 'DevTools::Debugger' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Comment 2•3 years ago
•
|
||
Thanks Mark for reporting!
Can you provide a link to webpage we can use to reproduce the issue?
Hi,
sry it's not possible (it is a customer portal and also behind VPN), so maybe this can help:
- it's .net MVC project with angular and this is a file structure in VS dev project and server (part of source included in attachment if could help)
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Comment 6•3 years ago
|
||
For the record, we managed to reproduce the bug. STRs available on https://test-case-bug1802515.glitch.me/
Comment 7•3 years ago
|
||
Bomsy, do you think we should close this as dupe of Bug 1603421, but bump the severity to P2? I don't think the initial bug captured how this was completely preventing from using the debugger.
I quickly tested on Chrome, and the behavior is very similar. The only minor difference is that it attempts to jump to the original file when you create the breakpoint, which maybe makes it a it clearer?
There are interesting discussions in Bug 1603421 about situations where only some files might be missing so you'd still like to preserve the sourcemap behavior for other files (potentially leading to inconsistencies in the callstack etc...). Would make sense to keep the conversation in one place, or do you think this bug is worth keeping on its own?
Comment 8•3 years ago
•
|
||
(In reply to Julian Descottes [:jdescottes] from comment #7)
Bomsy, do you think we should close this as dupe of Bug 1603421, but bump the severity to P2? I don't think the initial bug captured how this was completely preventing from using the debugger.
I quickly tested on Chrome, and the behavior is very similar. The only minor difference is that it attempts to jump to the original file when you create the breakpoint, which maybe makes it a it clearer?
Interesting... so Chrome seems to try to jump to the .ts file when the user tries to set the breakpoint (therefore the breakpoint never gets set). I notice we try to jump after the users sets the breakpoint and then tries to reload. For me the breakpoint seems to get hit and pauses (example on line 4) before it tries to jump to the .ts file.
There are interesting discussions in Bug 1603421 about situations where only some files might be missing so you'd still like to preserve the sourcemap behavior for other files (potentially leading to inconsistencies in the callstack etc...). Would make sense to keep the conversation in one place, or do you think this bug is worth keeping on its own?
Yeah, I think we could close this as a dupe of Bug 1603421. All the relevant discussions are over there, and its nice to keep it all in one place. The main thing Bug 1603421 lacks is a good STR, so we can use our usecase here to add an STR there.
Comment 9•3 years ago
|
||
Hi Mark,
Please see comment https://bugzilla.mozilla.org/show_bug.cgi?id=1603421#c7.
Does the test case match the issue you are seeing?
Thanks
Comment 11•3 years ago
|
||
(In reply to mark from comment #10)
yup :)
Great! Thanks.
I'm closing this bug in favour of Bug 1603421 as some discussions have already happened there and its nice to keep it all in one place.
Thanks
Updated•1 year ago
|
Description
•