Questions tagged [python-jedi]

Jedi is an autocompletion library for Python.

From the Jedi website:

Jedi is an autocompletion tool for Python that can be used in IDEs/editors. Jedi works. Jedi is fast. It understands all of the basic Python syntax elements including many builtin functions.

Additionaly, Jedi suports two different goto functions and has support for renaming as well as Pydoc support and some other IDE features.

To use Jedi, the library must be installed. Most users also install an editor plugin.

Plugins exist for Vim, Emacs, Sublime Text, and SynWrite.

53 questions
2
votes
0 answers

jedi Interpreter completion fails for properties

I would like to improve the auto-completion in a python console that is part of a project I am working on. While jedi works great for this in general, there is one special case where it fails to find any completion suggestions: Properties of classes…
Brow 71189
  • 21
  • 2
2
votes
0 answers

Jedi fails on autocomplete in sublime text

Jedi fails on autocomplete in sublime text for some cases: import os def x(y): print(y) print(x) f = open('1.txt', mode='r', encoding='utf-8'). # fail on dot from datetime import d # fail on module import I've got this error in both…
rmerkushin
  • 41
  • 1
  • 3
2
votes
2 answers

YouCompleteMe does not work for python

I'm not sure if this is some kind of bug (probably not, otherwise everyone would complain) and without a google account, I can't use the google group, so I try my luck here in the hope that somebody has a suggestion. I have YouCompleteMe installed…
oarfish
  • 4,116
  • 4
  • 37
  • 66
2
votes
3 answers

Emacs Jedi python tool unable to load "error searching for program: permission denied, python"?

I get the following error when I try to open a python file in emacs: can’t guess python indent offset, using defaults: 4 deferred error: (error searching for program: permission denied, python) My assumption is that the python environment…
Korey Hinton
  • 2,532
  • 2
  • 25
  • 24
1
vote
0 answers

How to recover the call chain of the functions calling the initially searched function?

I trying to come up with a script that could generate a sort of a list of the possible call chains on a project that could reach a certain function. Let's say we have the following modules models/user.py class User: def get_by_id(self, pk): …
Ramon Moraes
  • 477
  • 7
  • 23
1
vote
1 answer

What library or framework can be used to parse Python file and extract base classes as well as methods inside them

class A: def m1(): // in a.m1 pass class B(A): def m2(): // in b.m2 Parsing above code shall give me following info - class names - B, base -> A, method names -> a.m1, b.m2 I have looked into Jedi, but I don't see…
close2zero
  • 85
  • 8
1
vote
2 answers

Vscode shows function docstrings twice when using jedi + pyright

I am using VSCodium (an open source version of vscode) with jedi and pyright installed. This leads to function docstrings getting displayed twice (see attached picture), as jedi and pyright both show them. Is there a way to disable this single…
T-Dawg
  • 83
  • 6
1
vote
1 answer

Why does NeoVim, Coc, Jedi, Mypy, ... generate some_name.py.[git hash].py files?

I have a rather basic NeoVim setup with Coc for working with Python files. My Coc config looks like this: { "python.setLinter": ["mypy"], "python.linting.enabled": false, "python.linting.mypyEnabled": true, "python.formatting.provider":…
Achim
  • 15,415
  • 15
  • 80
  • 144
1
vote
0 answers

Trying to Install jedi: Errno 2

I am trying to install jedi using Windows Command Prompt. I type pip install jedi But I end up with this error: ERROR: Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: 'C:\\Users\\Adrian…
1
vote
0 answers

Python function arguments signature from docstring

Is there a solution to extract function args signature from docstring? Firstly, the parser should look for annotations and then fall back to docstring if there are no annotations. I found a similar question that works specifically for numpy…
dizcza
  • 630
  • 1
  • 7
  • 19
1
vote
0 answers

How to add IronPython stubs to jedi?

How to add a path for python jedi autocompletion. I downloaded Atom and the autocomplete-python package where I had the option to add the path to mine IronPython stubs. This works perfectly. I'm currently using jedi in a script and want it to look…
user3261212
  • 391
  • 2
  • 15
1
vote
1 answer

How to set signature for python callables manually

I want to offer a code completion for my pybind11 modules using Jedi. Jedi evaluates the __signature__ of callables for its completion. For more information see: Jedi struggles with pybind11 modules. But pybind11 is currently not able to generate…
stackomatiker
  • 324
  • 3
  • 14
1
vote
1 answer

How to get the types of numpy function arguments (from docstrings) using jedi in python

Ideally I would like a function which works as follows (for all kinds of numpy functions): parameter_types('np.random.binomial') and returns: {'a: 'int', 'b':'float', 'size':'int'} I understand that jedi has some support for extracting this…
hmelberg
  • 307
  • 1
  • 3
  • 8
1
vote
1 answer

python jedi code completion of returned object

I try to get neovim use jedi to do code completion but I get strange behavior when I start code completion on returned objects. It looks like jedi can not determine the returned objects type but in some cases it can. In case I mixed something up in…
Chris
  • 23
  • 5
1
vote
1 answer

Can't get Jedi's autocompletion on SuperTab

I installed both plugins using Pathogen, but they don't work together as it should be. That is, if I use TAB, I get SuperTab's completion (autocomplete what I have previously written) whereas if I use CTRL + SPACE I get Jedi's completion (everything…
user4093955