# Can't set Debugger breakpoints

**URL:** <https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972>\
**Category:** Developer Tools\
**Created:** [December 3, 2018, 9:07pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972 "2018-12-03T21:07:32Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Guy](https://avatars.discourse-cdn.com/v4/letter/g/9e8a1a/32.png) [@Guy](https://discourse.mozilla.org/u/Guy)\
**Post date:** [December 3, 2018, 9:07pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/1 "2018-12-03T21:07:32Z")

</div>

I can no longer set breakpoints in the Debugger. It have tried 3 different ways and nothing works. I click on the line number to set it and it acts like it will do it and then immediately refreshes without it being set. The prev.js file shws “pending” entries.

---

<div class="post-metadata">

**Author:** ![digitarald](https://avatars.discourse-cdn.com/v4/letter/d/c77e96/32.png) [@digitarald](https://discourse.mozilla.org/u/digitarald)\
**Post date:** [December 13, 2018, 4:57am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/2 "2018-12-13T04:57:20Z")

</div>

Which channel does this fail in?

Could you open the Browser Console from the tools menu and check it for related errors?

---

<div class="post-metadata">

**Author:** ![nick.devore](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/nick.devore/32/26985_2.png) [@nick.devore](https://discourse.mozilla.org/u/nick.devore)\
**Post date:** [April 17, 2019, 6:38pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/3 "2019-04-17T18:38:03Z")

</div>

I’ve got a bit more info on this. I cannot set breakpoints either, but it appears to be for inline javascript. I’m using [ASP.NET](http://ASP.NET) and have a `script` tag. It’s on the javascript inside that `script` tag that I can’t set a breakpoint. It seems like the debugger dosn’t recognize this as javascript. I’m on 67.0b10 Developer Edition

---

<div class="post-metadata">

**Author:** ![Slam](https://avatars.discourse-cdn.com/v4/letter/s/a9a28c/32.png) [@Slam](https://discourse.mozilla.org/u/Slam)\
**Post date:** [June 16, 2019, 4:11pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/4 "2019-06-16T16:11:02Z")

</div>

I’m having the same using Firefox Quantum 67.0.2 (64-bit).

---

<div class="post-metadata">

**Author:** ![nick2](https://avatars.discourse-cdn.com/v4/letter/n/3ec8ea/32.png) [@nick2](https://discourse.mozilla.org/u/nick2)\
**Post date:** [June 18, 2019, 10:07am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/5 "2019-06-18T10:07:51Z")

</div>

I also have this problem with Quantum 67.0.2 (64 bit).

Cannnot set breakpoint in script with an aspx file . Works in a script file.

---

<div class="post-metadata">

**Author:** ![frnx](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/frnx/32/28114_2.png) [@frnx](https://discourse.mozilla.org/u/frnx)\
**Post date:** [June 23, 2019, 9:22am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/6 "2019-06-23T09:22:46Z")

</div>

Same issue with Firefox Developer Edition 68b12 on Linux (Gnome Wayland). I cannot set breakpoints in a JS file…

The Browser console has no particular warnings/errors when I click on the JS debugger gutter to set a breakpoint.

---

<div class="post-metadata">

**Author:** ![aliadnan1984](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/aliadnan1984/32/28179_2.png) [@aliadnan1984](https://discourse.mozilla.org/u/aliadnan1984)\
**Post date:** [June 28, 2019, 10:42am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/7 "2019-06-28T10:42:36Z")

</div>

I am experiencing same issue on FF 67.0.4 64bit .  
**work around / fix**  
I found a bothersome work around / fix. if close the devtools and refresh the page and then open devtools , then the adding breakpoints start to work.  
but if I refresh the page while devtools are open , then after page refresh I can not add breakpoints by any method.

---

<div class="post-metadata">

**Author:** ![William\_Avery](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/william_avery/32/28218_2.png) [@William\_Avery](https://discourse.mozilla.org/u/William_Avery)\
**Post date:** [July 2, 2019, 11:13am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/8 "2019-07-02T11:13:51Z")

</div>

I am also on 67.0.4 (64-bit) and find the the JS inside script elements on a .aspx page has the line numbers light grey and inactive.

---

<div class="post-metadata">

**Author:** ![digitarald](https://avatars.discourse-cdn.com/v4/letter/d/c77e96/32.png) [@digitarald](https://discourse.mozilla.org/u/digitarald)\
**Post date:** [July 29, 2019, 9:17pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/9 "2019-07-29T21:17:48Z")

</div>

Sorry about that. This is a regression that slipped through that broke breakpoints in HTML files. 68 should have a fix.

---

<div class="post-metadata">

**Author:** ![lbarbareau](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/lbarbareau/32/21924_2.png) [@lbarbareau](https://discourse.mozilla.org/u/lbarbareau)\
**Post date:** [October 22, 2019, 10:40am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/10 "2019-10-22T10:40:51Z")

</div>

Same kind of issue in 69.0.3 (64bits)  
Some lines of code can’t receive breakpoints, but it may work sometimes after closing/reopening the debugger + refreshing the page…

---

<div class="post-metadata">

**Author:** ![digitarald](https://avatars.discourse-cdn.com/v4/letter/d/c77e96/32.png) [@digitarald](https://discourse.mozilla.org/u/digitarald)\
**Post date:** [October 22, 2019, 11:47am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/11 "2019-10-22T11:47:58Z")

</div>

@lbarbareau sorry to hear. Could help by testing in Nightly if you see the same issue?

---

<div class="post-metadata">

**Author:** ![lbarbareau](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/lbarbareau/32/21924_2.png) [@lbarbareau](https://discourse.mozilla.org/u/lbarbareau)\
**Post date:** [October 22, 2019, 12:44pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/12 "2019-10-22T12:44:29Z")

</div>

Ok, I distinguish 2 cases :

First case, maybe it’s normal because of a function that is declared twice at different locations, so it makes sens that the code into the first occurrence is not accessible (and then it could be useful to have something that shows clearly the dead code…).

Second case, maybe the parser identifies mistakenly some code as an overwriting. For instance, the presence of a jQuery call like “$(function() {” that appears twice or more… I can’t be sure of that but it looks like into my case.

---

<div class="post-metadata">

**Author:** ![digitarald](https://avatars.discourse-cdn.com/v4/letter/d/c77e96/32.png) [@digitarald](https://discourse.mozilla.org/u/digitarald)\
**Post date:** [November 4, 2019, 3:28pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/13 "2019-11-04T15:28:15Z")

</div>

In some cases that code gets GC’d before devtools is opened, so the Debugger doesn’t ever see the lines. This is fixed by having DevTools open, so the debugger can tell the JS engine to keep all code.

---

<div class="post-metadata">

**Author:** ![lbarbareau](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/lbarbareau/32/21924_2.png) [@lbarbareau](https://discourse.mozilla.org/u/lbarbareau)\
**Post date:** [November 5, 2019, 4:32pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/14 "2019-11-05T16:32:25Z")

</div>

DevTools is already opened into my case.

---

<div class="post-metadata">

**Author:** ![digitarald](https://avatars.discourse-cdn.com/v4/letter/d/c77e96/32.png) [@digitarald](https://discourse.mozilla.org/u/digitarald)\
**Post date:** [November 5, 2019, 8:57pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/15 "2019-11-05T20:57:05Z")

</div>

You did describe some cases where it fails, but so far I was unable to make a test case. Do you have anything at hand that could serve as a test case?

---

<div class="post-metadata">

**Author:** ![lbarbareau](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/lbarbareau/32/21924_2.png) [@lbarbareau](https://discourse.mozilla.org/u/lbarbareau)\
**Post date:** [November 8, 2019, 10:16am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/16 "2019-11-08T10:16:39Z")

</div>

I’ll try to isolate a case if I can but currently I have no time, sorry.

---

<div class="post-metadata">

**Author:** ![axelfriberg](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/axelfriberg/32/31645_2.png) [@axelfriberg](https://discourse.mozilla.org/u/axelfriberg)\
**Post date:** [November 11, 2019, 9:01am UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/17 "2019-11-11T09:01:14Z")

</div>

I am also having issues with breakpoints not being hit. I am running 70.0.1 (64-bit) on Mac. I am running the code locally through VS code with the Live Server extension. An example of where the breakpoint is not being hit is the following.

```
 sliderEl.noUiSlider.on("update", function(values, handle) {
      $("#value").text(values[handle]);

      if (values[handle] === 1) {
        $("#places").text("place");
      } else {
        $("#places").text("places");
      }
});

```

So placing a breakpoint in the callback function does not work. Tried in Chrome and there it works just fine.

---

<div class="post-metadata">

**Author:** ![bikesbytesbugs](https://avatars.discourse-cdn.com/v4/letter/b/b5a626/32.png) [@bikesbytesbugs](https://discourse.mozilla.org/u/bikesbytesbugs)\
**Post date:** [November 14, 2019, 8:48pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/18 "2019-11-14T20:48:43Z")

</div>

I just ran into this problem, where I was unable to set any breakpoints, and was able to resolve it by opening about:config and resetting (right click and select reset) two values:  
devtools.debugger.pending-breakpoints & devtools.debugger.pending-selected-location

---

<div class="post-metadata">

**Author:** ![digitarald](https://avatars.discourse-cdn.com/v4/letter/d/c77e96/32.png) [@digitarald](https://discourse.mozilla.org/u/digitarald)\
**Post date:** [November 19, 2019, 9:51pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/19 "2019-11-19T21:51:55Z")

</div>

Sounds like the code isn’t even minified. Did the suggestion from [Can't set Debugger breakpoints](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/18) help? If not, please check `Browser Console` for any error logs – that might give a clue.

---

<div class="post-metadata">

**Author:** ![John\_Webb](https://avatars.discourse-cdn.com/v4/letter/j/53a042/32.png) [@John\_Webb](https://discourse.mozilla.org/u/John_Webb)\
**Post date:** [November 20, 2019, 8:26pm UTC](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972/20 "2019-11-20T20:26:42Z")

</div>

I’m having similar issues with 70.0.1 64-bit.  
I can set the breakpoints and see the indicator. It shows up in the breakpoints list with a check in the checkbox. The deactivate breakpoints button is not indicating the breakpoints are deactivated and the code file is not black-boxed. Everything looks good except the debugger never breaks. However, the javascript is executed. So frustrating…

[Next page](https://discourse.mozilla.org/t/cant-set-debugger-breakpoints/33972.md?page=2)
