Skip to main content

Questions tagged [filetype-python]

Configuring and using vi/vim to edit python code. For scripting vim using python, use the /vimscript-python tag.

13 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
6 votes
0 answers

vim compiled with python3 but python3 omni-completion does not work

It used to work when I used python2, but now I can't use ^X^O to complete function names. I do have vim with -python and +python3 (on Ubuntu 16.04), but here is the error I get when trying Ctrl-X ...
PlasmaBinturong's user avatar
4 votes
0 answers

How do I setup Mypy with Neomake

I'm trying to use Mypy with Neomake, but without success. I am currently using flake8 with Neomake, and it works seamlessly, e.g.: def foo(bar): return 1 foo(1) > E305 expected 2 blank lines ...
Jay Lee's user avatar
  • 141
4 votes
0 answers

Highlight python raw strings as regular expression

I heard someone had set up their editor to highlight python raw strings as regular expressions, e.g. for Django: urls(r'^site1/(\d)*/new$'', ...) Unfortunately my googleing doesn't get me anything. ...
yggdrasil's user avatar
3 votes
0 answers

How to select a python interpreter in vim

I have multiple versions of python on my ubuntu system, python2.7 which is default one and i have installed python3.8. I have a python module installed in python3.8 which is not installed in python2.7....
Manoj's user avatar
  • 131
3 votes
0 answers

View pylint errors using coc and neovim

For the following code there is an error in the gutter, but I don't know how to view the actual message for it. Similarly here: In the bottom right of the editor are warnings and errors: But I don'...
baxx's user avatar
  • 1,025
3 votes
1 answer

Vim syntax for python call and keyword arguments: issues with built-in keyword

I am trying to come up with a Vim syntax for python function call, e.g.: foo(notarg==0, arg2, kwarg='a', kwarg2='b') dict(a=1, b=2, c=3) where we want to highlight (i) function name foo, dict (ii) ...
Jongwook Choi's user avatar
1 vote
0 answers

Ho to force the pyright language server to use a interpreter on a mounted volume

I have a problem with the following setup: the volume of a remote machine is mounted using sshfs nvim is opened on the mounted volume to ensure all my plugins and settings work ~/anaconda3/envs/.. is ...
cal's user avatar
  • 21
1 vote
0 answers

Signature pop-up describes dataclass as "The most base type"

I'm using coc-python for Python IDE-like features. If I define a dataclass I would expect the signature pop-up to show me which fields an instance of this class expects. Instead I get: MyClass() ------...
LondonRob's user avatar
1 vote
0 answers

Issue when creating files using python in vim

When writing or appending files using python inside vim, new files are not being created and existing files are not being changed. Creating and appending files in python script and atom text editor ...
user669132's user avatar
1 vote
0 answers

How to use external python modules with NeoComplete?

After trying out many auto-completion engines for Vim, NeoComplete combined with Jedi seems like a good choice for python development. However, I can't get it to use external libraries like PySide (Qt ...
tommyip's user avatar
  • 219
1 vote
0 answers

Ultisnips not working on first load of python file

I've installed the Ultisnips plugin with Pathogen. All in all it seems to be working fine. My problem is that it doesn't seem to work for the first python file I load, but it works for all the rest. ...
b4rdarian's user avatar
0 votes
1 answer

How can I solve this wrong behaviour in gf command?

For some reason, on a specific project I work on (no per project configuration on my side). The gf command does a replacement of the last dot to slash, as if I'm in a Java file, even though it is a ...
Guilherme Marthe's user avatar
0 votes
0 answers

How dose colorscheme file working when python.vim file not exist?

I deleted python.vim in ~./Vim/vim82/syntax directory, and define colorscheme.vim in ~./Vim/vim82/colors directory. The colorscheme.vim contain this code call <sid>hi('pythonNumber', s:...
hibernation's user avatar