clojure-emacs/ac-nrepl

Fail run ac-nrepl in *nrepl* and clojure-mode buffers.

kostafey opened this issue · 7 comments

The error is:

java.lang.NullPointerException: 
               Reflector.java:296 clojure.lang.Reflector.invokeNoArgInstanceMember
                     core.clj:118 clj-stacktrace.core/parse-exception
                     repl.clj:106 clj-stacktrace.repl/pst-on
                     repl.clj:129 clj-stacktrace.repl/pst+
                  RestFn.java:408 clojure.lang.RestFn.invoke
                     Var.java:415 clojure.lang.Var.invoke
                 NO_SOURCE_FILE:2 user/eval7
               Compiler.java:6511 clojure.lang.Compiler.eval
               Compiler.java:6477 clojure.lang.Compiler.eval
                    core.clj:2797 clojure.core/eval
                     main.clj:245 clojure.main/repl[fn]
                     main.clj:266 clojure.main/repl[fn]
                     main.clj:266 clojure.main/repl
                 RestFn.java:1096 clojure.lang.RestFn.invoke
        interruptible_eval.clj:51 clojure.tools.nrepl.middleware.interruptible-eval/evaluate[fn]
                     AFn.java:159 clojure.lang.AFn.applyToHelper
                     AFn.java:151 clojure.lang.AFn.applyTo
                     core.clj:601 clojure.core/apply
                    core.clj:1771 clojure.core/with-bindings*
                  RestFn.java:425 clojure.lang.RestFn.invoke
        interruptible_eval.clj:36 clojure.tools.nrepl.middleware.interruptible-eval/evaluate
       interruptible_eval.clj:164 clojure.tools.nrepl.middleware.interruptible-eval/interruptible-eval[fn]
                    core.clj:2278 clojure.core/comp[fn]
       interruptible_eval.clj:131 clojure.tools.nrepl.middleware.interruptible-eval/run-next[fn]
                      AFn.java:24 clojure.lang.AFn.run
                 (Unknown Source) java.util.concurrent.ThreadPoolExecutor$Worker.runTask
                 (Unknown Source) java.util.concurrent.ThreadPoolExecutor$Worker.run
                 (Unknown Source) java.lang.Thread.run

Hi -- please can you tell me how to reproduce this? Which Emacs / nrepl / nrepl.el versions are you using, and what symbol were you trying to complete?

Thanks,

-Steve

  1. GNU Emacs 24.2.1 (i386-mingw-nt5.1.2600) of 2012-08-29 on MARVIN
  2. nREPL 0.1.5-preview (automatically installed by nrepl.el)
  3. nrepl.el Version: 0.1.5 (installed from ELPA Version: 20120925.626)
  4. ac-nrepl.el Version: 0.1 (installed from ELPA Version: 20120920.821)

I'm just trying to write:

(de

wait a second and got the error trace described above.

I have the same versions of Emacs, nREPL and ac-nrepl, but a newer version of nrepl.el -- 20121003.626.

I've tried, but still can't reproduce this error, so you might consider trying the newer nrepl.el to see if it helps.

I have updated nrepl.el to version 20121003.626 (by removind and adding it again from ELPA), restart both Emacs and nrepl, but nothing changes.

Can I do something to help with debug the problem?

I'm not sure what to suggest at this stage. One thing you can check is whether this is specific to ac-nrepl: try commenting out the ac-nrepl setup code in your startup file, and then try nrepl.el's own tab completion after the "de" symbol. Does that produce the same error?

(Note: to upgrade packages, just use M-x package-list-packages, then press "U", followed by "x". All available upgrades will be installed, but you might need to restart Emacs for the new versions to be loaded.)

You are right it isn't specific to ac-nrepl. After commenting ac-nrepl's configuration code and restarting Emacs, the complete-symbol call produces the same error.

I should readdress the question. Thank you.

Makes sense. Both ac-nrepl and nrepl.el use similar code to perform the completion. In fact, ac-nrepl calls functions added to recent nrepl.el versions where available.