Skip to content
This repository has been archived by the owner on Dec 14, 2017. It is now read-only.

No such var: project/classpath (core.clj:51) #71

Closed
jwr opened this issue Oct 25, 2010 · 4 comments
Closed

No such var: project/classpath (core.clj:51) #71

jwr opened this issue Oct 25, 2010 · 4 comments

Comments

@jwr
Copy link

jwr commented Oct 25, 2010

cake swank:

Exception in thread "main" java.lang.Exception: No such var: project/classpath (core.clj:51)
at clojure.lang.Compiler.analyze(Compiler.java:5205)
at clojure.lang.Compiler.analyze(Compiler.java:5151)
at clojure.lang.Compiler$InvokeExpr.parse(Compiler.java:3057)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5371)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyze(Compiler.java:5151)
at clojure.lang.Compiler$InvokeExpr.parse(Compiler.java:3057)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5371)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyze(Compiler.java:5151)
at clojure.lang.Compiler$BodyExpr$Parser.parse(Compiler.java:4670)
at clojure.lang.Compiler$LetExpr$Parser.parse(Compiler.java:4941)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5369)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5357)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyze(Compiler.java:5151)
at clojure.lang.Compiler$BodyExpr$Parser.parse(Compiler.java:4670)
at clojure.lang.Compiler$FnMethod.parse(Compiler.java:4328)
at clojure.lang.Compiler$FnExpr.parse(Compiler.java:3173)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5367)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5357)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyze(Compiler.java:5151)
at clojure.lang.Compiler$HostExpr$Parser.parse(Compiler.java:798)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5369)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5357)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.access$100(Compiler.java:35)
at clojure.lang.Compiler$DefExpr$Parser.parse(Compiler.java:438)
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5369)
at clojure.lang.Compiler.analyze(Compiler.java:5190)
at clojure.lang.Compiler.analyze(Compiler.java:5151)
at clojure.lang.Compiler.eval(Compiler.java:5428)
at clojure.lang.Compiler.load(Compiler.java:5857)
at clojure.lang.RT.loadResourceScript(RT.java:340)
at clojure.lang.RT.loadResourceScript(RT.java:331)
at clojure.lang.RT.load(RT.java:409)
at clojure.lang.RT.load(RT.java:381)
at clojure.core$load$fn__4511.invoke(core.clj:4905)
at clojure.core$load.doInvoke(core.clj:4904)
at clojure.lang.RestFn.invoke(RestFn.java:409)
at clojure.core$load_one.invoke(core.clj:4729)
at clojure.core$load_lib.doInvoke(core.clj:4766)
at clojure.lang.RestFn.applyTo(RestFn.java:143)
at clojure.core$apply.invoke(core.clj:542)
at clojure.core$load_libs.doInvoke(core.clj:4800)
at clojure.lang.RestFn.applyTo(RestFn.java:138)
at clojure.core$apply.invoke(core.clj:542)
at clojure.core$require.doInvoke(core.clj:4869)
at clojure.lang.RestFn.invoke(RestFn.java:409)
at user$eval796.invoke(NO_SOURCE_FILE:1)
at clojure.lang.Compiler.eval(Compiler.java:5424)
at clojure.lang.Compiler.eval(Compiler.java:5391)
at clojure.core$eval.invoke(core.clj:2382)
at clojure.main$eval_opt.invoke(main.clj:235)
at clojure.main$initialize.invoke(main.clj:254)
at clojure.main$null_opt.invoke(main.clj:279)
at clojure.main$main.doInvoke(main.clj:354)
at clojure.lang.RestFn.invoke(RestFn.java:422)
at clojure.lang.Var.invoke(Var.java:369)
at clojure.lang.AFn.applyToHelper(AFn.java:165)
at clojure.lang.Var.applyTo(Var.java:482)
at clojure.main.main(main.java:37)
Caused by: java.lang.Exception: No such var: project/classpath
at clojure.lang.Compiler.resolveIn(Compiler.java:5651)
at clojure.lang.Compiler.resolve(Compiler.java:5621)
at clojure.lang.Compiler.analyzeSymbol(Compiler.java:5584)
at clojure.lang.Compiler.analyze(Compiler.java:5172)
... 65 more

Tried cake clean, also removing classes libs build. No effect. This is a project which uses clojure-protobuf. Here's what I do:

cake clean
cake deps
cake proto
cake swank

when I get the above, cake hangs and does not return to the shell.

I wanted to narrow it down, but frankly I have no idea how, as I don't understand the backtrace at all.

This is with current cake from git. Says it's 0.5.4.

@jwr
Copy link
Author

jwr commented Oct 25, 2010

Digging in: This seems to be caused by my tasks.clj (placed in the source directory for my project), in particular by the ns statement:

(ns fablo.tasks
(:use [clojure.contrib.duck-streams :only (read-lines)]
[clojure.contrib.java-utils :only (file)]
cake cake.core cake.ant
[cake.tasks.jar :only [build-uberjar uberjarfile]])
(:import [org.apache.tools.ant.taskdefs Mkdir Copy](java.io IOException)))

@jwr
Copy link
Author

jwr commented Oct 25, 2010

rm -rf ~/.m2/repository seems to have fixed the problem.

@ninjudd
Copy link
Owner

ninjudd commented Oct 25, 2010

hmm. i am unable to reproduce this. if you look in src/cake/project.clj there is a (def classpath ...). this is the file used by both cake.core and bake.core. could have been an old JVM running that didn't get restarted.

@jwr
Copy link
Author

jwr commented Oct 26, 2010

It was definitely not a running JVM, I killed all processes many times as I was trying to figure out what was going on. No amount of cleaning within the project directory did the trick, either. Finally, removing the maven repo did it, once and for good.

Maven is scary.

This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants