Closed MrGung closed 5 years ago
Did you install jdk?
This exception is thrown when the jdk tools.jar can not be found automatically. What OS are you running? what version of jdk?
Right - I used the JRE.
Thanks!
I'm using lein-ritz 0.6.0 with Win 7, and JDK 7 (javac -version returns javac 1.7.0_09). I get the same stack trace, despite having the JDK. I tried setting JAVA_HOME to C:\Program Files\Java\jdk1.7.0_09, and also to C:\Progra~1\Java\jdk1.7.0_09, with no luck.
@ramoncreager could you paste the output of lein-ritz --log-level trace
I'm using Windows 8, Java for Windows 1.7 and Cygwin. I had the same path issue like ramoncreager. I resolved it by setting the "Path" environment variable of my account in Windows to the bin path of my Java installation (C:\Program Files\Java\jdk1.7.0_10\bin). I also remove the java, javaw, javaws files in C:\Windows\System32.
I also had to put the profiles.clj file in the Windows home directory C:\Users\%user name%\AppData\Roaming, where also .emacs.d resides.
When I do 'lein ritz' with my - Leiningen 2.0.0-preview10 on Java 1.7.0 Java HotSpot(TM) 64-Bit Server VM - I get:
Exception in thread "main" java.lang.RuntimeException: java.lang.ClassNotFoundException: com.sun.jdi.VirtualMachine at clojure.lang.Util.runtimeException(Util.java:165) at clojure.lang.Compiler.eval(Compiler.java:6476) at clojure.lang.Compiler.eval(Compiler.java:6455) at clojure.lang.Compiler.load(Compiler.java:6902) at clojure.lang.RT.loadResourceScript(RT.java:357) at clojure.lang.RT.loadResourceScript(RT.java:348) at clojure.lang.RT.load(RT.java:427) at clojure.lang.RT.load(RT.java:398) at clojure.core$load$fn4610.invoke(core.clj:5386) at clojure.core$load.doInvoke(core.clj:5385) at clojure.lang.RestFn.invoke(RestFn.java:408) at clojure.core$load_one.invoke(core.clj:5200) at clojure.core$load_lib.doInvoke(core.clj:5237) at clojure.lang.RestFn.applyTo(RestFn.java:142) at clojure.core$apply.invoke(core.clj:602) at clojure.core$load_libs.doInvoke(core.clj:5271) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:602) at clojure.core$require.doInvoke(core.clj:5352) at clojure.lang.RestFn.invoke(RestFn.java:2793) at ritz.swank.proxy$eval269$loading4505auto__270.invoke(proxy.clj:1) at ritz.swank.proxy$eval269.invoke(proxy.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6465) at clojure.lang.Compiler.eval(Compiler.java:6455) at clojure.lang.Compiler.load(Compiler.java:6902) at clojure.lang.RT.loadResourceScript(RT.java:357) at clojure.lang.RT.loadResourceScript(RT.java:348) at clojure.lang.RT.load(RT.java:427) at clojure.lang.RT.load(RT.java:398) at clojure.core$load$fn4610.invoke(core.clj:5386) at clojure.core$load.doInvoke(core.clj:5385) at clojure.lang.RestFn.invoke(RestFn.java:408) at clojure.core$load_one.invoke(core.clj:5200) at clojure.core$load_lib.doInvoke(core.clj:5237) at clojure.lang.RestFn.applyTo(RestFn.java:142) at clojure.core$apply.invoke(core.clj:602) at clojure.core$load_libs.doInvoke(core.clj:5271) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:602) at clojure.core$require.doInvoke(core.clj:5352) at clojure.lang.RestFn.invoke(RestFn.java:408) at ritz.swank.socket_server$start.invoke(socket_server.clj:117) at user$eval3.invoke(NO_SOURCE_FILE:1) at clojure.lang.Compiler.eval(Compiler.java:6465) at clojure.lang.Compiler.eval(Compiler.java:6455) at clojure.lang.Compiler.eval(Compiler.java:6455) at clojure.lang.Compiler.eval(Compiler.java:6431) at clojure.core$eval.invoke(core.clj:2795) at clojure.main$eval_opt.invoke(main.clj:296) at clojure.main$initialize.invoke(main.clj:315) at clojure.main$null_opt.invoke(main.clj:348) at clojure.main$main.doInvoke(main.clj:426) at clojure.lang.RestFn.invoke(RestFn.java:421) at clojure.lang.Var.invoke(Var.java:405) at clojure.lang.AFn.applyToHelper(AFn.java:163) at clojure.lang.Var.applyTo(Var.java:518) at clojure.main.main(main.java:37) Caused by: java.lang.ClassNotFoundException: com.sun.jdi.VirtualMachine at java.net.URLClassLoader$1.run(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at clojure.lang.DynamicClassLoader.findClass(DynamicClassLoader.java:61) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) at ritz.jpda.jdi$eval275$loading4505auto__276.invoke(jdi.clj:1) at ritz.jpda.jdi$eval275.invoke(jdi.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6465)
In my profiles.clj I have: {:user {:plugins [[lein-ritz "0.4.0"]]}}
BTW Is using Clojure 1.4 a problem?