Closed benoitcerrina closed 5 years ago
ncdbg.log Attached is a log of the issue happening
Sorry for the delay! I will take a look tomorrow.
Huh, this is weird:
09:23:02.908 [NashornDebugger] DEBUG c.p.ncd.nashorn.ScriptPublisher - Adding script with ID 'nds236', URI 'xplan/xPlanDataAnalytics', hash '0CDE65D79F71A40B7B657627F17A77BF and version ScriptVersion(238,true)'
09:23:29.376 [NashornDebugger] INFO c.p.ncd.nashorn.NashornDebuggerHost - Setting an unresolved breakpoint with ID ndb3 at line 38 in script with URL lanDataAnalytics
Note xplan/xPlanDataAnalytics
vs lanDataAnalytics
.
Are you using a particular NCDbg version of the latest master?
I'm unable to reproduce. I have one small discrepancy compared to your log output though - which OS are you using?
Interestingly:
xplan/xP lanDataAnalytics
https://
The stripped part is equal in length to "https://". Perhaps a coincidence though.
Hello I am using windows 10 I think I am using the latest master unless I made a mistake using git so I will recheck
I confirm I am using the latest master.
Do you load scripts using the load
extension?
Also, what does the source tree in DevTools look like? Can you post a screenshot that shows the script in question?
Ok, I can reproduce by adding a sourceURL comment to my test script. Does your script contain sourceURL?
I found the following fix in DevTools:
https://github.com/ChromeDevTools/devtools-frontend/commit/6fc46fbf18af8001200fb9f60a55c2645eaaddf1
That fix is not in Chrome 69.0.3497.100, however.
I'm a bit reluctant to create a workaround if the fix above gets into Chrome soon anyway.
Can you remove sourceURL (if you have it) in the meantime?
Hello, if you are talking about a sourceURL comment in the script, there are none so I can't really remove them. Is there something else similar which could cause the problem or some other trace I can provide to help identify it.
That's odd - sourceURL was the only way for me to reproduce. Perhaps the correct way is to prefix all URLs with file:///.
You can try removing the v8only query string parameter from the DevTools URL. It may have side effects though.
hello removing the v8only query string worked in my first test. I will confirm to you tomorrow if it worked completely.
Thanks for your support
Hello, the fix works for me in all scenarios. Thank you.
hello did knowing that removing the v8only parameter help understand what is going on. Still unsure why see the problem and you don't and what could be the difference between our configurations
The v8only parameter enables some NodeJS logic inside the DevTools frontend, among other things the stripping of file:///
which in your case is problematic since the URL doesn't start with that prefix. Not sure why I'm not seeing the same thing unless I add sourceURL
to the script.
But I'll do some tests without v8only and if everything seems to work (as @Deepashreehg suggests) then I'll update the log message that shows the DevTools link to open in Chrome.
@provegard We had the same problem with scripting in Jira (we're working over here) and removing the v8only parameter fixed us up.
@brainopener thanks for letting me know! I will make a release where I remove the v8only
parameter (and possibly experimental
as well) from the link that is shown in the log. I've had some busy weeks though, so I haven't managed to find time for it.
Hello, recently (maybe a week or two ago) ncdbg stopped working correctly for me. In particular breakpoints don't work. I am using chrome version 69.0.3497.100