'Xcode won't pause at this breakpoint because it has not been resolved

Shortly after updating to Xcode 13.2.1 I started seeing some weird behaviour of breakpoints. When I run an app (in a simulator) some of my breakpoints change their look and turn to dotted blue outlined. Xcode does not stop execution at these breakpoints although code has been compiled, loaded and executed. I checked it in Console by adding some prints.

When I hover over breakpoint Xcode shows a message:

Xcode won't pause at this breakpoint because it has not been resolved Resolving it requires that:

  • The line at the breakpoint is compiled.
  • The compiler generates debug information that is not stripped out (check the Build Settings).
  • The library for the breakpoint is loaded.

All trivial solutions like reloading, reapplying breakpoints have not helped.

Did anybody else see something like this? Is there a way to solve it?

Screenshot for reference:

Xcode screenshot



Solution 1:[1]

Ok, so in my particular case rebooting laptop has helped. All breakpoints are now good. But it would still be nice to know the cause of the problem.

Solution 2:[2]

In my case the issue was happening, because class was not added to the target, which I was trying to build.

Solution 3:[3]

Make sure that the file in which you are adding breakpoint is having correct target set in target membership.

  1. Click on .m file in which you want to add breakpoint.
  2. Select the file inspector.
  3. Check if you have selected correct target for that file or not (check below image).

enter image description here

Solution 4:[4]

If tried everything and nothing worked I suggest the following:

  • Reclone your repo

This is what worked for me.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Artem Kirillov
Solution 2 phantom_2
Solution 3 pallavi
Solution 4 Kwnstantinos Nikoloutsos