Exception breakpooint for specific line.



I have Java program. How can I have exception breakpoint for specific line? Intellij has it's option for exception breakpoints but they are global meaning that anything, including frameworks can trigger those. How do I tell Intellij that I am only interested in those NPEs that come from line x file y and nothing else?


Feel free to upvote on the related issue in YouTrack - https://youtrack.jetbrains.com/issue/IDEA-12111 .

If you want to stop on exception in your code only, you can set class filter to include "org.my.*".

Please see https://www.jetbrains.com/help/idea/2022.2/using-breakpoints.html#breakpoint-properties for more information.


But looks like my name is still showing up there? It even offers restore option. The delete button I noticed myself too but it seemed stupid that my name would still appear there. Was curious if you had some real delete?


Sorry, I'm not sure I follow you. Can you please attach a couple o screenshots showing the actual/expected result? Thank you!


Please sign in to leave a comment.