Hi,
Stefan Kamphausen wrote:
> I'll take a look at it the next few days (er, evenings that is), if I
> find the time. No promises ;-)
Not that I'm close to a solution, but at least I have stacktrace...
After some digging in the clojure-swank code I came across this piece
in swank.clj:
(defn- connection-serve [conn]
(let [control
(dothread-swank
(thread-set-name "Swank Control Thread")
(try
(control-loop conn)
(catch Exception e
;; fail silently
nil)))
....
and I didn't like that comment. So I changed that to
(defn- connection-serve [conn]
(let [control
(dothread-swank
(thread-set-name "Swank Control Thread")
(try
(control-loop conn)
(catch Exception e
;; fail silently
(.printStackTrace e)
(.printStackTrace (.getCause e))
nil)))
Then after typing just "(+" into the SLIME-REPL-Buffer (obviously
without the quotes) I see a stacktrace in the *inferior-lisp*-Buffer:
user=> user=> Connection opened on local port 37693
#<ServerSocket ServerSocket
[addr=
0.0.0.0/0.0.0.0,port=0,localport=37693]>
user=> user=> java.lang.InterruptedException
at java.util.concurrent.locks.AbstractQueuedSynchronizer
$ConditionObject.reportInterruptAfterWait
(AbstractQueuedSynchronizer.java:1899)
at java.util.concurrent.locks.AbstractQueuedSynchronizer
$ConditionObject.await(AbstractQueuedSynchronizer.java:1934)
at java.util.concurrent.LinkedBlockingQueue.take
(LinkedBlockingQueue.java:358)
at swank.util.concurrent.mbox$receive__214.invoke(mbox.clj:28)
at swank.core$control_loop__249.invoke(core.clj:258)
at swank.swank$connection_serve__365$fn__397$fn__399.invoke(swank.clj:
29)
at clojure.lang.AFn.applyToHelper(AFn.java:171)
at clojure.lang.AFn.applyTo(AFn.java:164)
at clojure.core$apply__4305.invoke(core.clj:420)
at swank.swank$connection_serve__365$fn__397.doInvoke(swank.clj:26)
at clojure.lang.RestFn.invoke(RestFn.java:402)
at clojure.lang.AFn.run(AFn.java:37)
at java.lang.Thread.run(Thread.java:619)
Exception in thread "Swank Control Thread" java.lang.RuntimeException:
java.lang.NullPointerException
at clojure.lang.AFn.run(AFn.java:41)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.NullPointerException
at swank.swank$connection_serve__365$fn__397$fn__399.invoke(swank.clj:
33)
at clojure.lang.AFn.applyToHelper(AFn.java:171)
at clojure.lang.AFn.applyTo(AFn.java:164)
at clojure.core$apply__4305.invoke(core.clj:420)
at swank.swank$connection_serve__365$fn__397.doInvoke(swank.clj:26)
at clojure.lang.RestFn.invoke(RestFn.java:402)
at clojure.lang.AFn.run(AFn.java:37)
... 1 more
(I hope, google-group-posting will not mess with the pasted code, I
can see no preview-button on the posting-page)
And sending a SIGQUIT to the java-process shows that at least the
"Swank Control Thread" died (I think some other swank-threads, too).
What's most annoying is that I have not yet found a way to debug this
without restarting the JVM every few minutes. Still working on
this...
If anyone can give me a pointer where to look next, the help will be
highly appreciated.
Kind regards,
Stefan