Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

IPython is an interactive shell for Python.

1
vote
1answer
37 views

orgmode - ipython output image not show in results

I use below org code to draw a graph, but the graph not show on results block: #+BEGIN_SRC ipython :results drawer :session py2session %matplotlib inline import numpy as np import matplotlib.pyplot ...
0
votes
0answers
20 views

How to interrupt (Ctrl-C) process in elpy ipython console

For some reason I can't get the IPython console in emacs/elpy to catch the keyboard interrupt when I send it Ctrl-C. This makes interactive work in emacs/elpy very limited. Anyone have any ideas?
1
vote
1answer
89 views

emacs and anaconda ipython

I'm trying to get Emacs to start ipython from Anaconda. I have two systems which are not identical so figured setting symbolic links in ~/bin/ipython as I have ~/bin/ pre-pended to my $PATH would do ...
0
votes
0answers
15 views

IPython Shell magic function %hist outputs lots of junk history

I am using spacemacs with Emacs V26.1, with package elpy, on a Macbook. I believe this also happens on Windows. the issue is when I run the magic function %hist in the IPython shell, i got lots of ...
0
votes
0answers
63 views

Indentation Error when running Ipython shell (emacs/spacemacs, Windows)

I am a relatively new to emacs/spacemacs and my knowledge is quite basic, I have spacemacs set up with the python layer and have the indentation settings as follows: python-indent-offset is set to 4 ...
3
votes
0answers
101 views

Integrating jupyter notebook (ipython) into org-mode notebook

is there a way I can link in jupyter notebooks (ipython) into the org-mode notebook? The same way other files (images) can be brought in? If it is possible will the outputs are also seen in the note (...
0
votes
1answer
21 views

Can I create a shortcut for this operation?

I've been learning emacs the for last few days, trying to get some python development going, until I ran into this. Is it possible to create a shortcut to execute this command specificly? And if yes, ...
0
votes
0answers
79 views

Why is emacs telling me that I don't have ipython installed - “Searching for program: no such file or directory, ipython.”

I am a new emacs user and was following the guide here: https://realpython.com/emacs-the-best-python-editor/ In order to set up emacs as my default IDE. I have anaconda installed and updated. I ran ...
1
vote
0answers
39 views

Disable ipython show output in minibuffer

I am using Ipython 3.6.3 with Emacs(elpy enabled) 25.2.2 on Kubuntu 17.10. I realize that sometimes output of Ipython keep showing at minibuffer, which is very annoying. But, I cannot find the value ...
1
vote
0answers
160 views

debugging: how to optimize a RealGUD workflow

I code in Python and I my workflow uses debuggers (I coded for 8 years in Matlab). I develop numerical simulation codes: most of the time it returns a result, the question is: "Is the result right?" ...
4
votes
0answers
113 views

list of current variables in a buffer for Python code

I would like to find a way to reproduce the "Workspace" of Matlab or the equivalent "Variables" window of the awesome pudb debugger directly in emacs for python code: it is a window which details the ...
0
votes
1answer
84 views

Problem with emacs and input() using iPython 3.6.4

I am using emacs 25.2.1 Look at the following simple code: import sys def yes_no_barrier(message): print(message + ' (yes/no): ') while 1: s=str(input(message + ' (yes/no): ')) ...
1
vote
3answers
245 views

How to run blocks/cells of python code in emacs?

https://i.stack.imgur.com/TIxlR.png The picture shows what I mean by "block" - I mean a cell of code that is delimited by some sequence of characters, in this case '#%%', that can be executed by the ...
1
vote
0answers
96 views

Inferior Python shows not output, or input

I have the symptoms described here Input and Output does not show up in python mode, except this happens with python3 as interpreter as well as ipython, and I've tried the suggestions there for fixing ...
1
vote
1answer
359 views

how to set ipython on a virtualenv?

I'm using elpy for my python coding. I wanted to try ipython because of the nice built in profilers. So what I've done is to install ipython within my virtualenv. It works correctly. I then added the ...
3
votes
1answer
191 views

ob-ipython error message while evaluating SRC block

I am getting this error when executing any source ipython block such as this one: #+BEGIN_SRC ipython :session :results output drawer # Compute areas and colors import numpy as np import matplotlib....
1
vote
0answers
152 views

run python code interactively with emacs 25 on macos

I have always used emacs with python. I generally run my code on the ipython interpreter using C-c C-c. This is my ~/.emacs.d/init.el in ubuntu where everything works fine. (setq python-shell-...
1
vote
1answer
134 views

IPython doesn't work in a virtual environment

I've set up a virtual environment with venv and installed Ipython there via pip. On the terminal it works. Now, in my init.el, I have (setq python-shell-interpreter "ipython" python-shell-...
1
vote
0answers
245 views

show output from python-shell-send-region

Using python.el and ipython.exe (from Miniconda3), I'd like to highlight a portion of code and execute it in the associated inferior python buffer. Example: #!/usr/bin/python3 myvar = 100+200 ...
2
votes
1answer
192 views

Dedicated Python Shell?

I just upgraded emacs to 25.3. Before the upgrade when I opened a Python shell, it would ask me whether I wanted a 'dedicated' shell (for the buffer I was in), to which I usually replied 'yes'. Now, I ...
0
votes
0answers
43 views

IPython Completions Error

When using IPython as my Python interpreter I get the following error when trying to autocomplete a dictionary key (where | is where my cursor is when hitting TAB) test = {'a':1,'b':2} test['|.join(...
2
votes
2answers
752 views

‘python-shell-interpreter’ doesn’t seem to support readline

I am a complete newbie when it comes to emacs. I've got this problem with my 25.2.1 emacs running on Windows 10. Trying to run a python code results in the following error. Warning (python): Your ‘...
0
votes
0answers
208 views

Is it possible to have IPython qtconsole open as the default python console in Spacemacs?

Whenever I open a Python script in Spacemacs, I do C-c C-p to launch a console embedded - a console that is, by default, actually an iPython console. Here is what I would love to be able to ...
1
vote
0answers
76 views

Python-Repl issues with TRAMP Mode [windows->Linux]

I have an issue when using python-mode remotely through tramp. I'm trying to use the repl and pass a test function using C-c C-c, however this seems to create a local file at my own computer or ...
4
votes
1answer
108 views

ipython in emacs: Figure windows “not responding” on Windows 7

I am trying to get a good setup to do scientific python on windows 7. To be complete, I am using Anaconda for Python package management, and emacs 25.2 (the native windows build from GNU, not the ...
1
vote
0answers
475 views

Python inline plotting

I'd like to start using Emacs (Spacemacs) for my python work, however, a lot of what I do requires me to interact with the data in the IPython REPL, plot inline graphs, etc. For example, I might have ...
3
votes
1answer
3k views

Spacemacs use anaconda environment

I have anaconda environments for python2 and python3 as I have code written in the different versions In spacemacs (with python layer installed), when I open ipython (SPC m s i) it starts with my ...
4
votes
1answer
270 views

Problem of starting a remote ipython console

I want to connect to remote ipython server, and follow the doc of the ipython, I start a ipython server in my server by ipython3 kernel -f ~/.ipython/kernel.json --pprint and I can start a ipython ...
0
votes
1answer
130 views

Spacemacs Python Layer Invalid version syntax: '[?1034h4.0.0'

When I attempt to start Spacemacs with the Python layer enabled, I see a warning: Error (use-package): python :init: Invalid version syntax: '[?1034h4.0.0' Restarting emacs using --debug-init shows: ...
3
votes
1answer
502 views

Ipython completion in elpy

My elpy uses ipython as the interactive interpreter. It does not, however, emulate ipython's history-informed autocomplete feature (for lack of a better term). That is: within an ipython session ...
1
vote
0answers
118 views

Output of ipython shell much slower than python shell

Even turning off font-lock-mode and set (setq python-shell-font-lock-enable nil), the output of an ipython shell (setq python-shell-interpreter "ipython") seems much slow than the python shell (...
0
votes
3answers
465 views

ein failed to login to 8888

I was using emacs-ipython-notebook for data visualisation for some days.But then I started getting the error -ein failed to login to 8888.I checked my ipyhton notebook server and it's running on ...
3
votes
0answers
100 views

Lisp error with elpy under Python 3

I've had my emacs (v. 25.1.1) working with elpy (1.13) under Python 2.7 for a while. I decided to switch to Python 3 recently, and cannot get it to interact with emacs properly. Normally, when I ...
0
votes
1answer
131 views

Emacs python can not update imported files?

I am using spacemacs, anaconda-mode. In file main.py, I imported a class from file a.py. Then I pressed C-c C-p to launch an ipython shell, and run main.py, everything is OK. But then I modified the ...
6
votes
1answer
98 views

How can I access the :file src header argument inside the src block

I'm wondering how to access the :file header argument passed to a src block, from inside the src block itself? I'm wondering specifically for python, and in this case ipython with %matplotlib inline ...
0
votes
2answers
337 views

python emacs interpreter doesn't pause for input in loops

This looks like Weird shell output when using IPython 5, but it actually is not. I did set (setq python-shell-interpreter-args "--simple-prompt -i --pylab") in .emacs, but I get the following error:...
3
votes
1answer
105 views

ein + ipython non-responsive with python 'raw_input'

I am using Emacs with the ein package to edit ipython files. Everything works fine except when I have a line like: fhandle = raw_input('enter your file name: ') to prompt for a file name. The ...
2
votes
1answer
389 views

Setting `python-shell-interpreter-args` causes slow python mode enabling

I have a ipython config which imports lots of packages. I also have some configs in my python setup like (setq python-shell-interpreter "ipython3" python-shell-interpreter-args "-i --...
2
votes
1answer
736 views

Input and Output does not show up in python mode

I am using the Python mode with Emacs 25.1.1 to send parts of my python scripts to an ipython console. I have the problem that both the input and the output is not shown in the python window. Whenever ...
0
votes
0answers
155 views

python-mode breaks relative paths within script

I have my python setting within my .emacs (23.1.1) file set up as follows: (setq py-install-directory "~/.emacs.d/python/python-mode.el-6.0.11/") (add-to-list 'load-path py-install-directory) (...
2
votes
1answer
133 views

How do I filter for IPython prompt characters on Mac OS? [duplicate]

I've debugged to this point: OS X El Capitan (10.11.5) Emacs 24.5.1 with Cocoa (installed from homebrew) python.el 0.24.5 Python 3.5.1 IPython 5.0.0 I've configured IPython to use NoColor mode in ...
3
votes
2answers
570 views

Emacs freezes with ipython 5.0.0

My problem is Emacs with elpy, specifically with (elpy-use-ipython) in my init file. When I try to open a python file, emacs freezes. I desactivate ipython and emacs runs well. But I wanna use ...
6
votes
0answers
1k views

Emacs IPython prompt symbol is garbled

I just installed Fedora 24 with Emacs and IPython. When I launched the IPython shell in Emacs, the prompt symbol, which should be "In [1]", is displayed as "^[[?12l^[[?25h". Is there a way to solve ...
33
votes
1answer
6k views

Weird shell output when using IPython 5

I just upgraded to the latest version of IPython and now something is wrong when using it in emacs. When using it in a regular terminal it works fine (colors, tab-completion, etc.), however either ...
1
vote
1answer
1k views

elpy with ipython as rpc — how to get good autocompletion

I'm using elpy with emacs and python3. Here's the relevant part of my .emacs: ;; PYTHON (elpy-enable) (setq elpy-rpc-python-command "python3") (elpy-use-ipython "ipython3") (autoload 'jedi:setup "...
2
votes
1answer
405 views

ipython not working in org mode

I've followed everything here in order to set up ipython in org mode. But I keep getting the error: ...executing Ipython code block... apply: Searching for program: no such file or directory, ipython ...
0
votes
1answer
212 views

Problem working with python/pygame

I encounter this problem almost always when i am working on a python-pygame project. Every second time when i evaluate the whole buffer with C-c C-c or with C-c C-l the pygame window open for a very ...
0
votes
1answer
332 views

Inferior Python Shell - Windows - not printing results

I'm trying to use inferior python shell to run ipython commands interactively. I am able to connect but it doesn't print the results of my statements except when I use print statements In [1]: a = 10 ...
3
votes
2answers
473 views

ob-ipython error

I have Installed from Melpa ob-ipython on Ubuntu Xenial with Emacs 24. If I try to evaluate a source code like: #+BEGIN_SRC ipython :session %matplotlib inline importmatplotlib.pyplot as plt inport ...
3
votes
1answer
60 views

Force append to buffer instead of at point

Is it possible to force an Emacs buffer to place any new text it receives at the end of the buffer, instead of at the mouse point? I mean all of: keystrokes, yanks, mouse paste. I'm thinking in ...