WebStorm debug mode doesn't hit breakpoints - google-chrome

I have WebStorm successfully launching my app when I hit debug. It runs the app in chrome and Chrome tells me that that tab is in debug mode.
But it will not break on any breakpoint. I am using Ext JS and in the root app.js I have a breakpoint on the launch: function (which is being called) and that does not drop me into the debugger.
Does the WebStorm debugger not work with Ext JS?

I have the same situation as yours, except that I'm building my app using Backbone.js and RequireJs and the app is running on localhost. My app can run in debug mode in Chrome but the breakpoints cannot be hit.
I solve the problem by mapping the Remote URL and my local directory. You can define this in your JavaScript debug configuration profile in the Run->Edit Configurations.
You can refer to this wonderful tutorial: Debugging your JavaScript app using WebStorm.
Happy debugging!

Related

WebStorm 2019. Problem with connection of JavaScript debug mode

I have a next problem relation with as module JavaScript debug of WebStorm 2019. When I try to config my application into debug mode on my JavaScript modules, which have written on EcmaScript 6 standard of JavaScript languages. In below I have a next configure on debug mode of my JavaScript application:
Name of module: IndexPage
URL: http://localhost:63342/MatrixDraw/index.html
Browser: Chrome
Warning message: Waiting for connection http://localhost:63342. Please ensure that the browser started successfully on remote port debugging mode...
Warning message for waiting connection:
The file of mark up index.html was included with help bootstrap.js module. Just one file which I need to include into mark up stage data. And according to that file I have included in treedown stage technology data roots of chain dependencies of CommonJS ideologic.
How I can resolve that problem with debug mode?
P.S: Because in last versions of WebStorm (2014, 2015, 2016, 2017 and 2018) were working successfully on JavaScript debug mode and Node.js debug mode. And I have already to install and to config a module of plugin JetBrains into Chrome browser and activated that.
Try removing this file:
~\AppData\Roaming\JetBrains\WebStorm2020.2\options\other.xml
If that didn't work, in addition to the above, remove this file:
~\AppData\Roaming\JetBrains\WebStorm2020.2\options\web-browsers.xml
As always remember to take backups of your files.

Puppeteer authentication does not work in headless mode but yes in non headless mode

I'm facing up a strange problem in Puppeteer with authentication.
I've written a script to take some screenshot of a website which required authentication.
In my local computer (windows), when running in command line as node.exe my_script.js; it's working fine (in headless moden which is the default mode).
I've written an upper Java program to manipulate it (dynamically set the path, the node modules path, run the process "nodex.exe my_script.js" every 30minutes, manage timeout of the process,...). It's still working directly running from Eclipse, in headless mode.
Then... I've built/packaged a JAR and running it in a cmd window: java -jar my_jar.jar... and then the script can't authentitcated on the website in headless mode (the answser page just write a message like "you need to be authenticated", which is managed by the http server).
To check what happen, I've just add an option in my nodejs script (so I do not modify my java upper program code) to run chrome in non headless mode; with option headless : false. And... it's working!
I let the option to run in non headless mode, and I create a Windows service to run my jar via a bat file, with the help of nssm... Just to test. I'm really happy to see that all is running fine without seeing any chrome GUI (maybe Windows disable GUI for service, don't know how).
Have I maybe missed something? Or is there a bug in Puppeteer or Chrome to manage authentication in headless mode?
Regards
Alex

OnShareTargetActivated WindowsPhone 8.1 Target App crashes on debug

I'm trying to share Image to my Win 8.1 Phone App
When I select my app from share dialog.
The debugging in visual studio closes with error
Error:
Unable to start debugging 'U:\SharedData\PhoneTools\AppsLayouts\MyApp\MyApp.exe'
The object invoked has disconnected form client
When not debugging, in that case also the Target App Crashes
Any help to resolve this. I want to be able to debug my target app when activated through file sharing.
Follow these steps to debug your share target app.
Set breakpoints in your target app.
Check ‘Do not launch but debug my code when it starts’ in project properties.
Launch your app in debugger – nothing happens.
Run share client app to share image, select your app from share dialog.
Debugger attaches and breaks on your breakpoint.
Reference Debugging options in Deploying and debugging Universal Windows Platform (UWP) apps aticle.

Chrome: Attaching nacl-gdb to packaged application loaded as an unpacked extension

I have built a simple NaCl application. For running the application I use technique 2 described in Nacl Developer's guide, which means that instead of running a local server I load my application as unpacked extension to chrome. The application runs fine so far.
Now I want to experiment with nacl-gdb and attach my application to it at startup.
In the NaCl Developer's guide there are only instructions on how to attach nacl-gdb on an application that is run with local server(technique 1). I made a search to the internet and I ended up with the following approach in order to attach nacl-gdb for an application that is being ran with technique 2:
I enabled "Native Client GDB-based debugging" flag of Chrome.
I started chrome from a terminal like this: ./chrome "--nacl-gdb=gnome-terminal --
/media/sdb1/leonidasbo/AncientRoot/nacl_sdk/pepper_27/toolchain/linux_x86_glibc/bin/x86_64-nacl-gdb"
When Chrome launched, I navigated to my application.
With this approach, Chrome automatically started nacl-gdb when I opened my application.
However nacl-gdb tried to attach but with no success. The output was the following:
*This GDB was configured as "--host=x86_64-unknown-linux-gnu --target=x86_64-nacl".
Reading symbols from /opt/google/chrome/nacl_irt_x86_64.nexe...(no debugging symbols found)...done.
Don't know how to attach. Try "help target".
(gdb)*
It seems that gdb cannot attach to my application. I tried executing "target exec /path/to/my.nexe", but nothing changed.
Am I missing something here? Is there any other way to debug applications loaded as unpacked extensions with nacl-gdb?
My OS is Ubuntu 12.04 and I am using pepper_27 of nacl_sdk. Chrome version is 27.0.1453.93.
Thanks
I assume you were using this guide, which I was using earlier as well. It is out of date. These are the real instructions. It seems that the way you attach the debugger has completely changed, and it is no longer possible to use --nacl-gdb (that is planned for removal). You must manually attach the debugger by following these steps.
The full guide is here, but I'll summarize:
Launch Chrome with chrome --enable-nacl --enable-nacl-debug --no-sandbox --disable-hang-monitor.
Run <NACL_SDK_ROOT>/toolchain/win_x86_newlib/bin/x86_64-nacl-gdb (with no arguments).
Enter these commands into the gdb prompt:
(gdb) nacl-manifest <path-to-your-.nmf-file>
(gdb) nacl-irt <CHROME-DIR>/nacl_irt_x86_64.nexe
(gdb) target remote localhost:4014
Now you can use gdb as normal. (If you just want to run the application until it crashes, start by typing continue.)

Flash Builder debugger error : Flash builder failed to connect to running application

I am trying a simple code for event handling. I applied break point on a line of action script code of event. I want to see the debug window to check which event is generated. It does not show me any error but whenever i click the debug button i get the following problem
The Flash Builder debugger failed to connect to the running application.
Ensure that:
For in-browser applications, you are running the debugger version of Flash Player.
For network debugging on a mobile device, you have a reliable network connection to the device, and port 7935 is open on your machine's firewall.
My project runs correctly in browser showing the desired output but it shows me launching failed dialog with above error. Please help
One other thing you can try which worked for me when the above didn't - in Flex Compiler in Properties for the project, untick Generate HTML wrapper file, apply that, then tick it again and apply again. Seems to clean/reset the project in some way, which 'clean project' doesn't.
Try to shutdown "adl.exe" in taskmanager, It seens the old adl.exe occupied port 7935 that flashplayer can't creat new one.
That's how I solved it.
It happens many a time, but you can solve it in 4 ways
1) Clean the project and try.
2) Close flex builder and reopen it. try it, If that doesn't work than go for 3 option
3) Change your workspace and import that project in it or best is create new one and make the changes in it, Sometimes the workspace get corrupted and so it happens...
4) If above 3 option that doesn't work than reinstall your Flex builder, make sure that you uninstall flex builder properly.
I had exactly that symptom. Blank browser window, a freeze at 57% for 2 minutes and the same error message.
The problem was an error in my javascript. As usual, it just silently aborts whatever it is doing. As a result, the SWF was never started and the debugger failed to connect to the running program.
So, if the browser window remains blank it is probably a javascript error. Display the javascript console to see what is going on.
When I faced this issue what I had to do is re-install the adobe flash debugger version for firefox and Flash could successfully run in debug mode
Reason for the error : The firefox updates the flash builder version which for some reason doesn't work with the Adobe Flash Builder 4.6
You can follow below steps and get the flash application run in the debugger mode :
1) Go to https://www.adobe.com/support/flashplayer/debug_downloads.html
2) Download : [Download the Flash Player content debugger for Firefox - NPAPI][1]
3) Install the downloaded executable and install it over whatever version of Adobe Flash
builder that you have .
4) Restart the Flash Builder and run the application in debugger mode and check if it
works.