[OS X Emacs] error message with Gallina's python-mode.el
John Hale
jthale at uga.edu
Wed Jul 31 10:01:37 EDT 2019
Hi everyone — I'm seeking a simple python mode where I can press C-c C-r and send an expression to an inferior python
I added a Different Python Mode as directed at
https://www.emacswiki.org/emacs/CustomizeAquamacs#toc14
namely Fabián E. Gallina's python-model.el
It works well enough for sending expressions, but I always get this error:
Warning (python): Your ‘python-shell-interpreter’ doesn’t seem to support readline
...
Native completions have been disabled locally.
and the modeline declares "Shell native completion is disabled, using fallback"
of course, my python (v3.6.8, Dec. 24, 2018 https://www.python.org/downloads/mac-osx/ ) *DOES* have readline
Since I am using Aquamacs 3.4 which corresponds to GNU Emacs 25.3.50.1
I tried the fix mentioned here
https://emacs.stackexchange.com/questions/30082/your-python-shell-interpreter-doesn-t-seem-to-support-readline
but that doesn't work. I don't see what's wrong, since in the inferior buffer I get:
python.el: native completion setup loaded
suggesting that the python-shell-completion-setup-code did run successfully.
on the other hand, evaluating the expression (python-shell-completion-native-setup) directly
yields this error which makes me think it went looking for that special confirmation string and didn't find it:
looking-back: Invalid search bound (wrong side of point)
I'm guessing the search that's going wrong is the one specified in python.el near line 3416
(save-excursion
(re-search-backward
(regexp-quote "python.el: native completion setup loaded") nil t 1))
But I am not enough of an elisp hacker to tell what's going wrong.
Has anybody gotten this to work properly on Aquamacs? I ask because I'd like to be able to point students
to an Aquamacs setup that works the same as what they'll be seeing on a shared machine that has Emacs 24.3.1
where C-c C-r does really send a region to the inferior buffer.
best,
-john
PS
I did try with the Aquamacs-bundled python-mode.el by Andreas Röhler
but there the send command is bound to C-| and seemed to always send the entire buffer, regardless of how the region is set.
I could not figure out how to get around this. If this could be made to work, it would also achieve my desired goal.
SSN transport rule bypass code: 810-23-2567-984-015
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://email.esm.psu.edu/pipermail/macosx-emacs/attachments/20190731/a81734ed/attachment.htm>
More information about the MacOSX-Emacs
mailing list