簡體   English   中英

Emacs + Rope + Python會產生lisp錯誤

[英]Emacs + Rope + Python produces lisp error

我正在嘗試在Emacs中使用Ropemacs和AutoComplete,但我一直收到調試器錯誤:

Debugger entered--Lisp error: (void-function rope-completions)
  (rope-completions)
  eval((rope-completions))
  eval-last-sexp-1(nil)
  eval-last-sexp(nil)
  call-interactively(eval-last-sexp nil nil)

符號rope-completions沒有來自Ch S的文檔。它只出現在auto-complete-config中一次。 我已經下載了最新的ropemacs,ropemode,pymacs,python-rope,並且可能已經完成了我所擁有的任何系統一致性。

當我從配置文件中刪除此功能時,auto-complete在嘗試完成時將光標變為紅色。 我無法在我的系統上找到對此功能的引用。

在Lisp中,Auto-complete對我來說非常合適。 如何讓自動完成和Rope一起工作,讓我在Emacs中自動完成Python?

編輯:我無法通過Ch f看到繩索完成的定義。 這是我的Pymacs緩沖區的輸出:

<23 (version "0.24-beta2")
>45 eval pymacs_load_helper("ropemacs", "rope-")
<278    (return '(progn (pymacs-defuns '(0 rope--OldProgress nil 1 rope--LispProgress nil 2 rope-LispUtils nil 3 rope-message nil 4 rope--lisp-name nil 5 rope--load-ropemacs nil 6 rope--started-from-pymacs nil 7 rope-occurrences-goto "" 8 rope-occurrences-next "")) (pymacs-python 9)))
>45 eval pymacs_load_helper("ropemacs", "rope-")
<288    (return '(progn (pymacs-defuns '(10 rope--OldProgress nil 11 rope--LispProgress nil 12 rope-LispUtils nil 13 rope-message nil 14 rope--lisp-name nil 15 rope--load-ropemacs nil 16 rope--started-from-pymacs nil 17 rope-occurrences-goto "" 18 rope-occurrences-next "")) (pymacs-python 19)))
>51 eval free_python(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 19)
<13 (return nil)
>45 eval pymacs_load_helper("ropemacs", "rope-")
<279    (return '(progn (pymacs-defuns '(19 rope--OldProgress nil 9 rope--LispProgress nil 8 rope-LispUtils nil 7 rope-message nil 6 rope--lisp-name nil 5 rope--load-ropemacs nil 4 rope--started-from-pymacs nil 3 rope-occurrences-goto "" 2 rope-occurrences-next "")) (pymacs-python 1)))

你的emacs設置中有這樣的東西嗎? (另見: agr / ropemacs / overview - Bitbucket

(require 'pymacs)
(pymacs-load "ropemacs" "rope-")

如果你有,請檢查你是否有ropemacs命令,例如rope-open-projectCx po )。

請注意, rope-completions被定義為python函數,因此您不會在elisp源中看到它的定義。

如果你正確加載Ch f rope-completions RET當你擊中Ch f rope-completions RET (而不是Ch S )時,你會看到這個。

rope-completions is an interactive Lisp function.

(rope-completions &rest ARGUMENTS)

It interfaces to a Python function.

我最終能夠做到的唯一方法是忽略所有其他教程,只使用Emacs For Python Github。 它工作得很好,結合了我想要使用的很多軟件包,並且很容易配置,這樣它就不會搞砸我現有的綁定和設置。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM