Intermittent error
maacl opened this issue · 16 comments
From time to time I get an error looking like the below. Most of the time everything works fine, and I haven't been able to determine exactly what triggers the error. I am using nREPL 0.1.8-preview and ac-nrepl 20130420.929.
Debugger entered--Lisp error: (args-out-of-range 1 143)
count-lines(143 1)
popup-create(143 69 20 :min-height 0 :around t :margin-left nil :margin-right nil :scroll-bar nil :face popup-tip-face :parent nil :parent-offset nil)
popup-tip("clojure.core/take\n([n coll])\nReturns a lazy sequence of the first n items in coll, or all items if\nthere are fewer than n.\n" :point 143 :height 20 :min-height 0 :around t :parent nil :parent-offset nil :point 143 :height 20 :nowait t)
apply(popup-tip "clojure.core/take\n([n coll])\nReturns a lazy sequence of the first n items in coll, or all items if\nthere are fewer than n.\n" :point 143 :height 20 :min-height 0 :around t :parent nil :parent-offset nil (:point 143 :height 20 :nowait t))
popup-menu-show-quick-help([cl-struct-popup 143 8 0 10 10 nil 1 [#<overlay from 146 to 146 in core.clj> #<overlay from 147 to 147 in core.clj> #<overlay from 148 to 148 in core.clj> #<overlay from 149 to 149 in core.clj> #<overlay from 150 to 150 in core.clj> #<overlay from 151 to 151 in core.clj> #<overlay from 152 to 152 in core.clj> #<overlay from 153 to 153 in core.clj> #<overlay from 154 to 154 in core.clj> #<overlay from 155 to 155 in core.clj>](keymap %28mouse-5 . ac-mouse-5%29 %28mouse-4 . ac-mouse-4%29 %28down-mouse-1 . ac-ignore%29 %28mouse-1 . ac-mouse-1%29 %2819 . ac-isearch%29 %2816 . ac-previous%29 %2814 . ac-next%29 keymap %28C-up . ac-quick-help-scroll-up%29 %28C-down . ac-quick-help-scroll-down%29 %2867108927 . ac-help%29 %28M-f1 . ac-persist-help%29 %28f1 . ac-help%29 %28up . ac-previous%29 %28down . ac-next%29 %2827 keymap %2857 . ac-complete-9%29 %2856 . ac-complete-8%29 %2855 . ac-complete-7%29 %2854 . ac-complete-6%29 %2853 . ac-complete-5%29 %2852 . ac-complete-4%29 %2851 . ac-complete-3%29 %2850 . ac-complete-2%29 %2849 . ac-complete-1%29 %2816 . ac-quick-help-scroll-up%29 %2814 . ac-quick-help-scroll-down%29 %2867108927 . ac-persist-help%29 %28112 . ac-previous%29 %28110 . ac-next%29 %289 . auto-complete%29%29 %28return%29 %2813%29 %28tab . ac-expand%29 %289 . ac-expand%29) nil 0 ac-candidate-face ac-candidate-mouse-face ac-selection-face popup-summary-face 1 0 nil t t 0 0 0 0 (#("take" 0 4 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v")) #("take-nth" 0 8 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v")) #("take-last" 0 9 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v")) #("take-while" 0 10 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v"))) 9 nil (#("take" 0 4 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v")) #("take-nth" 0 8 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v")) #("take-last" 0 9 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v")) #("take-while" 0 10 (selection-face ac-nrepl-selection-face popup-face ac-nrepl-candidate-face document ac-nrepl-documentation symbol "v")))] nil :point 143 :height 20 :nowait t)
ac-quick-help()
apply(ac-quick-help nil)
byte-code("r\301�\302H�\303H"\210)\301\207" [timer apply 5 6] 4)
timer-event-handler([t 0 0 500000 0.5 ac-quick-help nil idle 0])
accept-process-output(nil 0.005)
nrepl-send-request-sync(("ns" "com.jayway.rps.core" "op" "eval" "session" "c6135125-2940-4693-bdaa-741f1e075b90" "code" "(require 'complete.core) (filter #(.startsWith % "ta")(complete.core/namespaces ns))"))
nrepl-send-string-sync("(require 'complete.core) (filter #(.startsWith % "ta")(complete.core/namespaces ns))" "com.jayway.rps.core" "c6135125-2940-4693-bdaa-741f1e075b90")
ac-nrepl-sync-eval("(require 'complete.core) (filter #(.startsWith % "ta")(complete.core/namespaces ns))")
ac-nrepl-candidates_("(filter #(.startsWith % "ta")(complete.core/namespaces *ns_))")
ac-nrepl-candidates-ns()
ac-candidates-1(((candidates . ac-nrepl-candidates-ns) (symbol . "n") (available . ac-nrepl-available-p) (candidate-face . ac-nrepl-candidate-face) (selection-face . ac-nrepl-selection-face) (prefix . ac-nrepl-symbol-start-pos) (document . ac-nrepl-documentation)))
ac-candidates()
ac-update(t)
ac-show-menu()
apply(ac-show-menu nil)
byte-code("r\301�\302H�\303H"\210)\301\207" [timer apply 5 6] 4)
timer-event-handler([t 0 0 400000 0.4 ac-show-menu nil idle 0])
What version of popup.el
do you have? Googling for the error showed results that pointed the finger upstream at popup
.
I have version 20130324.1305 of popup.el installed.
On Tue, Apr 30, 2013 at 9:37 PM, Steve Purcell notifications@github.comwrote:
What version of popup.el do you have? Googling for the error showed
results that pointed the finger upstream at popup.—
Reply to this email directly or view it on GitHubhttps://github.com//issues/33#issuecomment-17249414
.
Same version as I have, then.
I don't see any mention of this issue over at https://github.com/auto-complete/popup-el/issues
Nonetheless, I don't think this is something ac-nrepl
is doing wrong: we're just providing a string for auto-complete
to display using popup
. If it's a popup bug, it could be related to the exact cursor position and the text line lengths, since it has to figure out how to size and place the popup. That would inevitably result in seemingly random behaviour.
I'll keep this issue open for now, but I can't really take any action to resolve it. :-)
Ok, thanks. Is it bad form to submit to the popup-el repo too?
On Tue, Apr 30, 2013 at 9:54 PM, Steve Purcell notifications@github.comwrote:
Same version as I have, then.
I don't see any mention of this issue over at
https://github.com/auto-complete/popup-el/issuesNonetheless, I don't think this is something ac-nrepl is doing wrong:
we're just providing a string for auto-complete to display using popup.
If it's a popup bug, it could be related to the exact cursor position and
the text line lengths, since it has to figure out how to size and place the
popup. That would inevitably result in seemingly random behaviour.I'll keep this issue open for now, but I can't really take any action to
resolve it. :-)—
Reply to this email directly or view it on GitHubhttps://github.com//issues/33#issuecomment-17250302
.
No, I think it would be helpful to file the stacktrace there too.
The AC guys have reverted with this response:
"This may happen when generating candidates in asynchronous. ac-nrepl should pass 4th argument to accept-process-output to suppress timers to fire. Could you please make a bug report and send it to ac-nrepl team?"
Thanks for following up with the auto-complete
guys!
ac-nrepl
uses a synchronous call into nrepl
to generate candidates, but under the covers, nrepl
is fully asynchronous, and that's where the code is which deals with process output. Any timer suppression would have to take place inside nrepl
-- as time permits, I'll look into that. :-)
Thanks - weird that not more people have reported this. Wonder if I did
something weird to my set-up that accentuates this.
/mac
On Fri, May 3, 2013 at 3:25 PM, Steve Purcell notifications@github.comwrote:
Thanks for following up with the auto-complete guys!
ac-nrepl uses a synchronous call into nrepl to generate candidates, but
under the covers, nrepl is fully asynchronous, and that's where the
code is which deals with process output. Any timer suppression would have
to take place inside nrepl -- as time permits, I'll look into that. :-)—
Reply to this email directly or view it on GitHubhttps://github.com//issues/33#issuecomment-17393775
.
On Fri, May 3, 2013 at 2:39 PM, Martin Clausen notifications@github.comwrote:
Thanks - weird that not more people have reported this. Wonder if I did
something weird to my set-up that accentuates this.
Did you use nrepl-ritz by any chance ? I found nrepl-ritz+ac-nrepl unusable
because of (I think) this problem.
Nope - no ritz in sight :-)
On Fri, May 3, 2013 at 3:58 PM, Neale Swinnerton
notifications@github.comwrote:
On Fri, May 3, 2013 at 2:39 PM, Martin Clausen <notifications@github.com
wrote:
Thanks - weird that not more people have reported this. Wonder if I did
something weird to my set-up that accentuates this.Did you use nrepl-ritz by any chance ? I found nrepl-ritz+ac-nrepl unusable
because of (I think) this problem.—
Reply to this email directly or view it on GitHubhttps://github.com//issues/33#issuecomment-17395338
.
I just noticed that the symbol next to the completion candidates is "v" and not "n" as stated in the readme - is this significant?
It's significant that the README is wrong, but the "v" is correct. Sam split up the completions into different categories, so the symbols are different if they're variables, functions etc.
Some more feedback. The issue has not resolved itself after uninstalling elpy. I wonder what weirdness elpy does to interfere with other users of ac.
Just to confirm, "has not resolved itself"? The rest of your comment suggested you thought elpy might be a problem.
Sorry, has resolved itself.
Okay, great - I'll go ahead and close this then.