completion doesn't work on GNU Emacs (mac)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python-mode.el |
Fix Committed
|
Medium
|
Andreas Roehler |
Bug Description
- Emacs Version 24.3 (from http://
- python 2.7.5 (shipped by Apple)
- python-mode version 6.0.10 (from package.el)
When I completing in "*Python*" buffer, the completion didn't work.
In that buffer, after I typed "import socket", and in the next line "socket.<TAB>", then the buffer shows
>>> exec '''\ndef print_completio
(I marked the point at the end of line as '_')
Don't know why it does not execute the line but stopped at that line.
But, when I press <RET>, then it shows the completion as expected.
Changed in python-mode: | |
importance: | Undecided → Medium |
assignee: | nobody → Andreas Roehler (a-roehler) |
Changed in python-mode: | |
status: | New → Fix Committed |
Am 24.02.2014 15:24, schrieb Seong-Kook Shin: emacsformacosx. com/) ns(namespace, text, prefix=''):\n for name in namespace:\n if name.startswith (text): \n print(prefix + name)\n\ndef complete(text):\n import __builtin__\n import __main__\n if '.' in text:\n terms = text.split('.')\n try:\n if hasattr(__main__, terms[0]):\n obj = getattr(__main__, terms[0])\n else:\n obj = getattr( __builtin_ _, terms[0])\n for term in terms[1:-1]:\n obj = getattr(obj, term)\n print_completio ns(dir( obj), terms[-1], text[:text. rfind(' .') + 1])\n except AttributeError:\n pass\n else:\n import keyword\n print_completio ns(keyword. kwlist, text)\n print_completio ns(dir( __builtin_ _), text)\n print_completio ns(dir( __main_ _), text)\ncomplete ('socket. ')''' in {}^M_
> Public bug reported:
>
> - Emacs Version 24.3 (from http://
> - python 2.7.5 (shipped by Apple)
> - python-mode version 6.0.10 (from package.el)
>
> When I completing in "*Python*" buffer, the completion didn't work.
>
> In that buffer, after I typed "import socket", and in the next line "socket.<TAB>", then the buffer shows
>>>> exec '''\ndef print_completio
>
> (I marked the point at the end of line as '_')
>
> Don't know why it does not execute the line but stopped at that line.
>
> But, when I press <RET>, then it shows the completion as expected.
>
Checked in a fix. Please tell it it's done for you.