IntelliJ IDEA: ClassNotFoundException if run Debug, execution/run does work

回眸只為那壹抹淺笑 提交于 2019-12-09 10:09:04

问题


I have a Java Maven Project started in Eclipse, worked on it a few days, then imported it in IntelliJ IDEA, again working on it a few days.

The normal Run/Execution in IDEA and via shell does work, but not the Debug.

When I click the Bug Icon for Debug, it opens up URLClassLoader.java file and points on the Line "throw new ClassNotFoundException(name)" and pauses the Debug, if I click Resume Debug, it shows several Classes that do not belong to my project. I can click the Resume Button endless, it shows the same classes, also ClassNotFoundException over and over again in a continuously loop and does not debug my source.

If I click Build -> Rebuild Project it says at the Debug icon "Hot Swap failed myClassname: schema change not implemented; myClassname: Operation not supported by VM"

In the Debug window under Variables it says: "Frame is not available"

The Debug of this project in IntelliJ IDEA did work previously, whats wrong now?


回答1:


Looks like you have an exception breakpoint on ClassNotFoundException. Please try to open Run | View Breakpoints... and uncheck the breakpoint under "Java Exception Breakpoints".




回答2:


This is really helpful. Go to your breakpoints in debug mode and make sure to deselect all the breakpoints first and then select only the ones in your class.




回答3:


in my situation, just neglect the evaluate language drop down.



来源:https://stackoverflow.com/questions/27820035/intellij-idea-classnotfoundexception-if-run-debug-execution-run-does-work

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!