Chrome Dev Tools stops at breakpoint even when breakpoints are deactivated - javascript

I encountered an issue while debugging Javascript in the Dev Tools in Chrome.
Even when I have deactivated the breakpoints from the button, it still stops at them.
like this
I haven't enabled the "Pause on exceptions" button and the only thing that works is when I disable the breakpoints one by one (not having 'tick' on them).
disabled breakpoint
I noticed that this appeared in a week or so.
My browser is Version 78.0.3904.108 (Official Build) (64-bit)

It happened to me when I had another browser tab open on the same domain and the dev tool was open in that other tab too.
in that case you need to decative the debugger in both tabs or better close the other tab.

Edit: The issue is gone now, with the last update from chrome.

Related

how to totally ignore 'debugger' statement in chrome?

'never pause here' can not work
after I continue:
still paused
To totally ignore all breakpoints in Chrome, you must do as follows:
Open your page in the Chrome browser.
Press F12 or right-click on the page and select Inspect.
In the Source panel, press Ctrl+F8 to deactivate all breakpoints. (or: At the top-right corner, select deactivate breakpoints.)
All breakpoints and debugger statements will be deactivated.
I tested it in Chrome 79.0.3945.88 (64-bit) and I found that the debugger statement is ignored.
To stop hitting debugger statements, you must either set a "never pause here" breakpoint, OR you must pause stopping on exceptions.
This works because debugger breakpoints are considered exceptions by the browser.

Chrome automatically blocks javascript when open Developer (F12)

I have a problem with Chrome running on my PC.
Websites are running fine on Chrome, but whenever I open developer tools (F12), Chrome blocks that site's javascript. Keep the developer tools opened, and refresh the page (F5), Chrome loads the site with without any scripts.
This happens to all websites.
Incognito mode doesn't encounter the issue.
I checked settings in Chrome and it allows JS.
I tried to disable extensions, doesn't work.
I re-installed Chrome, doesn't work.
I tried to run using a different Chrome user account. Work fine.
But I am a developer so I don't want to use incognito mode all the time or use different account.
Please help,
Hoang
Edit:
* Add screenshot
Select settings from "Inspect element window" and untick the "disable Javascript" check box

Debugging JavaScript in IE11

The F12 tools look good, and I see controls for most of what I would like to use (Continue, Step In, Step Out). But the HTML app I want to debug runs before I can start the F12 tools. What I need is a Restart button, it would seem to me.
Am I missing seeing this, or am I out of luck?
By the way, I see the same problem in Chrome.
Open your Page.
Press F12 to display the tools.
Switch to the debugging tab.
Add your breakpoints.
Refresh by pressing F5 or Ctrl+F5 orCtrl+R.

How to make Google Chrome JavaScript console persistent?

Since I'm building a dynamic site, I need to track the changes between pages, ie. Ajax calls, POST, GET stuff and similar stuff.
I'm looking for the same functionality like in Firebug (where you can enable "persistent" and the console is not cleared every time you reload a page or submit a form.
So, my questions is: is there a way to make Google Chrome JavaScript console persistent?
(And if yes, how?)
Update: Copying the answer here, if anyone's still looking for this, Chrome 14+ has a setting in Developer Tools > Settings labelled "Console: Preserve log on navigation".
Update 2: the latest versions of Chrome (33+) have this option by right-clicking in the console.
Update 3 (late 2017): The latest versions of Chrome (60+) have this option by opening the console, clicking the gear in the top right corner and selecting "preserve log"
If anyone's still looking for this, I'm on Chrome 15.0.874.58 beta-m and I have a checkbox in Developer Tools > Settings labelled "Console: Preserve log on navigation". Does the job nicely.
at Version 67.0.3396.87 (Official Build) (64-bit)
Unfortunately, Chrome doesn't support that functionality yet, although there was talk in December 2010 about adding in the next major release...
This answer is no longer valid
As of Chrome Version 73.0.3683.86 (Official Build) (64-bit):
Click the ellipsis in top right of Developer Tools
Navigate to Settings > Preferences > Console
Check Preserve log upon navigation
Try this to enable console on popups
I had the "preserve logs" options enabled and still had the Console losing focus to the Sources tab. If that happens (apparently during debugging), it helps to disable "Focus sources panel when triggering a breakpoint" in "Settings > Preferences > Sources".
In Chrome v102
I opened Chrome Dev Tools,
I clicked on "gear" icon (Top right corner)
Enable "Preserve log" checkbox

IE8 javascript debugger is now broken

I am on Windows 7, using IE8 and Visual Studio 2005. I have been enjoying the built in javascript debugger in IE8 for several months. About 2 weeks ago, I installed some security update for IE 8 (possibly KB978207) and all of a sudden the javascript debugger is now broken.
If I get a warning from IE 8 that an error occurred and asking if I want to debug using the built in debugger, if I hit yes, I get a grey popup in the top left corner (which I've never seen before) saying "JScript Debugger. Breaking on JScript runtime error - Object doesn't support this property or method". Then nothing happens. IE freezes up and then I get a Windows popup saying that IE 8 is no longer responding and asking if I want to end this process. If I try to end the process, nothing happens and I continue to get the grey popup. I usually have to kill debugging process from VS 2005, but the frozen IE8 still is present. It's not until later when the OS, finally cleans up the process that it will go away...
Edit (new info):
I tried removing the lastest security update and a silverlight update that came around the same time, but Windows automatically reinstalled them....
I then tried removing IE 8, and then adding it back to my system to reset anything related to IE8. This did not have any effect.
After reinstalling IE8, I did notice that, when I first tried to open the developer tools window by hitting F12 from a regular IE 8 window, I never saw anything, but I could see the developer tools title in the task manager list. I had to right click on the task and maximize the window, so I could actually see the developer tools window. Apparently this is a bug mentioned here: http://social.msdn.microsoft.com/Forums/en-US/iewebdevelopment/thread/79b8ee54-c5f6-4467-ba6d-27491c95cd13
I've realized that the window will maximize if the iexplorer.exe process is not the debugged process launched from VS2005.
The grey popup I mentioned in my original post is from the developer tools window iexplorer.exe process.
If I launch my app from VS2005 and then hit F12, I see that the developer tools window is opened (I can see that window is opened under the IE icon in my taskbar), but it is not shown. If I try to maximize it from the task manager, this has no effect.
So basically, the developer tools window is freezing up when it tries to open under my debugged iexplorer.exe process launched from VS2005. The OS then asks if I want to kill the process since it's not responding, but it is unable to kill it. At some later point, the zombie iexplorer.exe process is killed succesfully (by the OS I presume).
Had the same thing happening. You clued me in on the solution by pointing out F12 starts Developer Tools in the taskbar but doesn't show up on the screen. Apparently the window is off screen in nowhere land and causes major screwups if you attempt to debug in this state. So my solution was to:
Close all IE instances
Start up IE
Start up Developer Tools (F12)
Hover cursor over the the IE button on the taskbar until context menu shows
Right-click the Developer Tools item in the context menu (not the taskbar button)
Click "Move"
Start tapping arrows until you see the window come back in view. Mine was off stage left so I had to hold down the right arrow.
The window will have been sized down to just a window title bar, so resize by dragging the right corner down and out.
Once the window is moved back and resized, close it to "set" the position. You should be good to go now.
May be the security patch has disabled script debugging in IE. It was a common problem when using the debugger of VS 200X
Now on try to enjoy FireFox with the FireBug Addon. It's really great to debug Javascript. :)

Categories

Resources