Questions tagged [elpy]

Elpy is an Emacs package to bring powerful Python editing to Emacs. It combines a number of other packages, both written in Emacs Lisp as well as Python.

Filter by
Sorted by
Tagged with
0
votes
1answer
2k views

emacs: reinstall package after installation error

I'm new to Emacs. I needed to install the elpy package for python (as described here), but as I forgot to install one python package with pip, the installation with M-x package-install RET elpy failed....
3
votes
0answers
924 views

How to use the auto-completion of jedi while keeping other functions of elpy?

Currently, I have both elpy and jedi installed. init.el is like: (elpy-enable) (elpy-use-ipython) (setq elpy-rpc-backend "jedi") (add-hook 'python-mode-hook 'jedi:setup) (setq jedi:complete-on-dot t)...
2
votes
0answers
322 views

Unexpected Indentation in Python interpreter

I am getting an indentation error in the Python interpreter while using elpy: >>> for i in range(1, 3): ... print(i) File "<stdin>", line 1 print(i) ^ IndentationError: ...
3
votes
2answers
687 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 ...
2
votes
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 "...
0
votes
1answer
954 views

Problem to install/setup elpy

I am trying to install elpy on my machine (ubuntu 14.04), but getting the following issue. any comment, hint? Thanks. Requirement already satisfied (use --upgrade to upgrade): elpy in ./work/...
2
votes
1answer
2k views

How to customize the line character length in elpy?

I am using elpy for my Python development, but I would like to set the per-line character limit to 120 instead of the default 80 used by PEP8. Any suggestions on how I can do this? Even better, it ...
5
votes
4answers
2k views

Function to restart python console

I wrote a very simple function to properly restart ipython console with elpy when evaluating the buffer or region: (defun my-restart-python-console () "Restart python console before evaluate buffer ...
0
votes
1answer
303 views

Force elpy to work only with .py extension files

Elpy works in every buffer automaticly, however I wan it to work only with python files. The related section of my init.el is: (require 'elpy) (elpy-use-ipython) (setq-default indent-tabs-mode nil) (...
1
vote
0answers
50 views

Sometimes experiencing heavy load using elpy

I have a couple of times experienced an elpy (Emacs Python development environment) python process using a considerable amount of CPU resources, loading the computer to an extent that I had to kill ...
2
votes
0answers
386 views

elpy-importmagic-add-import without rearranging imports?

The auto-importing functionality of elpy is awesome. However, it rearranges all the previous import statements in the file alphabetically. This is problematic for me because: I prefer to arrange my ...
1
vote
2answers
952 views

Define main file to always be run on C-c C-c in emacs elpy

When I am working on a file in my application in emacs/elpy, I always have to jump back into my main file buffer and do C-u C-c C-c (i.e. ) in order to run and debug it in the python shell. This is ...
2
votes
1answer
293 views

How to customize files pattern while using rgrep?

elpy-mode internally uses this command to search for a regexp in *.py files. (setq elpy-rgrep-file-pattern "*.py") (rgrep regexp elpy-rgrep-file-pattern default-directory)) However ...
23
votes
3answers
17k views

How to set up elpy to use python3?

When setting up my emacs for a new work environment, I am unable to get the elpy configuration to correctly use python 3. I have installed all of the required packages in /usr/local/bin and have ...
5
votes
1answer
728 views

Autocompletion using company in org src buffer?

I can't seem to get completion when editing an org-babel source code block. Elpy and company-mode both appear to be enabled minor modes for the buffer, but no completion candidates appear as they do ...
3
votes
1answer
466 views

Emacs 24 with Elpy 1.7.50 does not recognize Python Project

Note: This was initially posted on StackOverflow a few months back and hasn't received an answer, but I'm reposting it since the Emacs StackExchange is now available. I'm in the process of converting ...
0
votes
1answer
89 views

py-indent-or-complete leaves the *Python Completion* buffer open

I experience when using TAB bound to py-indent-or-complete that it gives me completion suggestions. however when leaving, or deciding the completion, the *Python Completion* buffer is left open ...
1
vote
1answer
113 views

Delete marked region with py-electric-backspace py-electric-delete

In my python-mode the backspace and delete keys gets remapped to py-electric-backspace, etc. This breaks the behaviour set by the variable delete-active-region. Is there a way to unify the behaviour ...
3
votes
1answer
1k views

How to use elpy and non-python autocomplete

Elpy provides company-mode to handle autocompletion. The way it is set up, company only turns on when I am in something handled by Elpy. If I enable auto-complete it works in non-python files, but ...
3
votes
1answer
1k views

how to remove the red underline

Occasionally I have this ugly red underline in my python code. It seems not related to any flymake error/warnings. Does anyone know why it shows and how it can be removed? Thanks! I am using latest ...
9
votes
3answers
3k views

How can I defer loading elpy using use-package?

I've been updating all my use-package calls now that :idle is no longer a decent way to defer stuff. At the moment one of the biggest hits on my load time is elpy which loads a whole bunch of ...