srusskih / SublimeJEDI

awesome Python autocompletion with SublimeText
MIT License
938 stars 109 forks source link

SublimeJEDI not working with Anaconda #225

Closed ghost closed 7 years ago

ghost commented 7 years ago

I have been trying to get Jedi to work with Sublime, but have been unsuccessful so far. Any help would be appreciated.

I am using Anaconda for Python 3.6 and my SublimeJEDI User settings are given below:

{
    "python_interpreter": "<PATH TO ANACONDA>/Anaconda3/python.exe",
    "python_package_paths": 
    [
        "<PATH TO ANACONDA>/Anaconda3/Lib/site-packages"
    ],
    "auto_complete_triggers": 
    [
        { "selector": "source.python", "characters": "." }
    ],
    "auto_complete_selector": "-"
}
srusskih commented 7 years ago

try remove "python_package_paths" from settings due to "<PATH TO ANACONDA>/Anaconda3/python.exe" already known about that path.

any errors/messages from ST console?

ghost commented 7 years ago

@srusskih
I have solved the issue (at least I think so).

I removed "python_package_paths" like you suggested, but this wasn't enough. It seems Anaconda (the Sublime Text package; not the Python distribution) was causing the issue. Whenever the package was active, auto-complete only had Sublime's default word suggestions, even though "disable_anaconda_completion", "suppress_word_completions", and "suppress_explicit_completions" were all set to true (These are Anaconda options). Don't know if this is a problem with just my machine.

I also noticed that JEDI was slow the first time it tries to load all the methods and other suggestions from a Python package. Is this normal?

srusskih commented 7 years ago

first usage can be slow, that's OK.

srusskih commented 7 years ago

Are you talking about this Anaconda package? - https://packagecontrol.io/packages/Anaconda

Jedi and the Anaconda packages could be used for auto-completion. That's why use had to turn off completion by Anaconda.

ghost commented 7 years ago

@srusskih I know that the Anaconda package can also be used for auto-completion. But I had turned off everything related to Anaconda's auto-complete; "disable_anaconda_completion", "suppress_word_completions", and "suppress_explicit_completions" were all set to true