I figured out the cause of my problem. It is the presence of incanter!
Having it in leiningen project.clj file as a dependency causes "lein swank" to
throw the following error:
C:\projects\pasclj>lein swank
Exception in thread "main" java.lang.IllegalArgumentException: No value
supplied for key: 4005 (NO_SOURCE_FILE:1)
at clojure.lang.Compiler.eval(Compiler.java:5440)
at clojure.lang.Compiler.eval(Compiler.java:5414)
at clojure.lang.Compiler.eval(Compiler.java:5415)
at clojure.lang.Compiler.eval(Compiler.java:5391)
at clojure.core$eval.invoke(core.clj:2382)
When I remove [incanter "1.2.3"] from my project.clj file the problem goes away.
Obviously there is some incompatibility between incanter and swank-clojure.
Anybody else face this issue or know of how to make incanter work with
swank-clojure?
Thanks
Shoeb
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of
Phil Hagelberg
Sent: Monday, June 06, 2011 12:16 AM
To: Clojure
Subject: Re: swank-clojure/lein/emacs
On Jun 5, 9:09 am, "Bhinderwala, Shoeb" <[email protected]>
wrote:
> I installed clojure-mode from marmalade. I added the following to my
> .emacs file:
>
> (add-to-list 'load-path "~/.emacs.d/elpa/clojure-mode/")
> (require 'clojure-mode)
This is not necessary; if you install via marmalade then the autoloads
will handle this for you.
> And also added the following to my lein project.clj file:
>
> :dev-dependencies [[swank-clojure "1.2.1"]]
This is a rather old version of swank. You should stick with 1.3.1 at
least.
> When I perform step 3 from within EMACS, and specify the path to my lein
> project.clj file, I get the following error:
>
> Starting swank server...
> cd c:/projects/pasclj && lein jack-in 1187: exited abnormally with
> code 1.
This is probably due to the old swank version.
> Also when I execute the following command "lein swank" from the command
> line, I get the following error:
>
> C:\projects\pasclj>lein swank
> Exception in thread "main" java.lang.IllegalArgumentException: No value
> supplied for key: 4005 (NO_SOURCE_FILE:1)
> at clojure.lang.Compiler.eval(Compiler.java:5440)
> at clojure.lang.Compiler.eval(Compiler.java:5414)
> at clojure.lang.Compiler.eval(Compiler.java:5415)
> at clojure.lang.Compiler.eval(Compiler.java:5391)
> at clojure.core$eval.invoke(core.clj:2382)
> ....
There's also a bug when mismatched versions are in lib/dev vs ~/.lein/
plugins that can cause behaviour like this. It's best not to put swank
in dev-deps at all but just stick with "lein plugin install". Just
inspect ~/.lein/plugins to make sure only 1.3.1 is in there. I'll
update the readme to explain this issue.
-Phil
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en