简体   繁体   中英

tab-completion not work in emacs shell running ipdb (but in normal bash shell it works)

I have been trying A LOT tips & tricks from various stackoverflow discussions and a lot more, but I cannot solve this problem, please help:

What works in my bash shell:

I have this python script:

a = [44, 22]
import ipdb
ipdb.set_trace()

when I run it, I get the ipdb prompt as expected and when I type "a. TAB" then some auto-complete function suggest all functions like this:

ipdb> a.
a.append   a.count    a.extend   a.index    a.insert   a.pop         a.remove   a.reverse  a.sort  

What NOT works in my EMACS shell:

When I do the same thing, but then from within an emacs shell, the tab completion does not work. I mean both the TAB and M-TAB. In this case Emacs tells me "No match". By the way: the M-TAB does complete when I am editing a python file. This whole thing is somewhat of a nuisance for me (this is a big understatement).

I have installed many of the suggested packages:

auto-complete      1.5.0        installed  Auto Completion for GNU Emacs
company            0.8.11       installed  Modular text completion     framework
concurrent         0.3.2        installed  Concurrent utility functions for emacs lisp
ctable             0.1.2        installed  Table component for Emacs Lisp
deferred           0.3.2        installed  Simple asynchronous functions for emacs lisp
elpy               1.7.0        installed  Emacs Python Development Environment
epc                0.1.1        installed  A RPC stack for the Emacs Lisp
find-file-in-pr... 3.3          installed  Find files in a project quickly.
highlight-inden... 0.5.0        installed  Function for highlighting indentation
jedi               0.1.2        installed  Python auto-completion for Emacs
popup              0.5.2        installed  Visual Popup User Interface
python-environment 0.0.1        installed  virtualenv API for Emacs Lisp
pyvenv             1.6          installed  Python virtual environment interface
yasnippet          0.9.0.1      installed  Yet another snippet extension for Emacs.

By the way: the option Mx RET jedi:install-server is not available in this set-up.

My environment:

ubuntu 14.04 LTS
emacs 24.3.1

What I also tried:

I also tried (and did also not work) using the unstable melpa source ( http://melpa.milkbox.net/packages ) which installed the packages:

auto-complete      20150218.819 installed  Auto Completion for GNU Emacs
company            20150224.... installed  Modular text completion framework
concurrent         20150205.616 installed  Concurrent utility functions for emacs lisp
ctable             20140304.... installed  Table component for Emacs Lisp
deferred           20150205.616 installed  Simple asynchronous functions for emacs lisp
elpy               20150206.... installed  Emacs Python Development Environment
epc                20140609.... installed  A RPC stack for the Emacs Lisp
find-file-in-pr... 20141214.... installed  Find files in a project quickly.
highlight-inden... 20150122.44  installed  Minor modes for highlighting indentation
jedi               20150217.... installed  Python auto-completion for Emacs
popup              20150116.... installed  Visual Popup User Interface
python-environment 20140321.... installed  virtualenv API for Emacs Lisp
pyvenv             20150218.... installed  Python virtual environment interface
yasnippet          20150212.240 installed  Yet another snippet extension for Emacs.

By the way: the option Mx RET jedi:install-server IS available in this set-up.

Any ideas ... ?

Sean Farley recently has made a pull request for ipdb into realgud . When I get the time, that will go in. In his fork, or when this is pulled, you can us Mx realgud-track-mode and give "ipdb" as the debugger to track. Supposedly with that there is tab expansion. However I'm not a ipdb user, so I haven't verified this.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM