question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Python completions not working

See original GitHub issue

I only get normal identifier completions + UltiSnips completions and the completions show up with slight delay. Some facts:

  • Vim (8.0.311) is compiled with python3
  • Jedi is installed globally with sudo pip3 install jedi
  • Jedi is importable in python3 shell
  • In python3 shell print sys.executable gives /usr/bin/python3
  • I have let g:completor_python_binary = "/usr/bin/python3" in my .vimrc
  • :CompletorDisable makes the (identifier+UltiSnips) completions instant
  • :CompletorEnable makes the (identifier+UltiSnips) completions have slight delay
  • completor.vim version is e9897d6, latest as of writing
  • I have no other completers installed in Vim

What am I missing and how could I debug this more?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
marallacommented, Oct 23, 2017

You can add this config:

let g:completor_filetype_map = {'python.django': 'python'}
0reactions
abidibocommented, Oct 20, 2017

About @Decent1 problem, I find convenient to set autocmd Filetype python set ft=python.django in my local vimrc for django projects, also because ultisnips will load the django snippets. Many other plugins (I think) work by matching with regexp, or perhaps dot separated words the filetype, in other words, I would expect to have python semantic completion available with a filetype which is python.django.

I’ve currenlty forced this behavior editing the pythonx/completor/__init__.py file, and adding a map item

 _type_map = {
     b'c': b'cpp',
     b'python.django': b'python',
     b'javascript.jsx': b'javascript'
}

at line72.

@maralla is there a better way to support this behavior?

Thanks for this great plugin!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Visual Studio Code: Intellisense not working - Stack Overflow
Open the commands window by simultaneously pressing CTRL/CMD + Shift + P . Now search for install extensions . Select Python and install...
Read more >
Python completion not working in Quarto for Visual Studio Code
When running Python chunks code completion is not working in qmd files. I installed the Quarto extension in VScode from the marketplace.
Read more >
IDLE: Fix tab completion after settings and some keys
I did a little experiment, and it turned out that the problem is not in the IDLE, but inside Python itself.
Read more >
Python Code Completion not working #940 - GitHub
Describe the bug Python code completion don't work in VSCodium as it works out of the box in the proprietary editor.
Read more >
Code completion | PyCharm Documentation - JetBrains
Troubleshooting ... If code completion doesn't work, this may be due to one of the following reasons: ... Your file doesn't reside in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found