Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IntelliJ IDEA 2017.1 does not stop on breakpoints

I have an old Gradle project that I've opened recently using the new IDEA 2017 and I have just noticed it will not stop on breakpoints anymore (these are active, but not "validated" - no checkmark on them.

The code is run locally (a gradle run/debug config without any options) with bootRun as the gradle task.

I have tried an Invalidate Caches/Restart without any success. I have also tried re-importing the project in IDEA.

A while back I had the same issue after upgrading to Spring 1.4.5 (if I remember correctly). I couldn't figure out why, so I downgraded back to 1.4.2 and everything worked fine. However, this time I'm running Spring 1.2.4 and I cannot upgrade to a newer version without changing some code (and I don't want that yet)

like image 288
CatalinM Avatar asked Apr 09 '17 19:04

CatalinM


People also ask

Why are my breakpoints not working?

If a source file has changed and the source no longer matches the code you're debugging, the debugger won't set breakpoints in the code by default. Normally, this problem happens when a source file is changed, but the source code wasn't rebuilt. To fix this issue, rebuild the project.

How do I stop debugging in IntelliJ?

Terminate a debugger sessionClick the Stop button in the Debug tool window. Alternatively, press Ctrl+F2 and select the process to terminate (if there are two or more of them).

How do you stop breakpoints?

To Disable a Single Breakpoint In the Query Editor window, right-click the breakpoint, and then click Disable Breakpoint. In the Breakpoints window, clear the check box to the left of the breakpoint.

What does a tick on a breakpoint mean in IntelliJ?

Their documentation Describes the checkmark as "Shown at run-time when the breakpoint is recognized by the debugger as set on an executable code line."


1 Answers

Well... for some reason, creating a Gradle run/debug config would make it connect to the wrong port (something random over 50000) while the application was running on 8080.

Anyway, long story short, creating an Application run/debug config solved the issue and everything works fine now.

like image 194
CatalinM Avatar answered Oct 12 '22 15:10

CatalinM