syl20bnr / spacemacs

A community-driven Emacs distribution - The best editor is neither Emacs nor Vim, it's Emacs *and* Vim!
http://spacemacs.org
GNU General Public License v3.0
23.68k stars 4.89k forks source link

Can't load anaconda-mode in python file #6608

Closed lsytj0413 closed 4 years ago

lsytj0413 commented 8 years ago

Error Message:

Making python-shell-interpreter local to  *Python Internal [792caf12c778150badeeede64c068cee]* while let-bound!
Making python-shell-interpreter-args local to  *Python Internal [792caf12c778150badeeede64c068cee]* while let-bound!
Loading semantic/db-file...done
Configuring package eldoc...done
File mode specification error: (error "Selecting deleted buffer")
Can't guess python-indent-offset, using defaults: 4
Configuring package anaconda-mode...done

When i first open an python-file, it comes with the Selecting deleted buffer Error, and the completion doesn't work. But if i close the python-file and then open it again, the anaconda-mode configuring message is out, and the competion works fine.

I also notice that the ISSUE #1862 and ISSUE #1505, But this doesn't work for me.

liuchengxu commented 8 years ago

I also encountered the same problem. Emacs can't load expected major mode when first open a python file, which was loaded with Python/la. However, the following python files opened would be loaded with right python mode Python.

update: Remove semantic layer toughly, the above problem was fixed for me.

lsytj0413 commented 8 years ago

@xuliuchengxlc Thank you for your help. Remove semantic works for me.

dzhwinter commented 8 years ago

+1 but remove semantic is not work for me

leezu commented 8 years ago

I run into this error if the first python file that I open is below a .python-version file (from pyenv, setting a virtual environment). If I open a python file that is not in a subfolder of a .python-version file no error occurs. Opening a python file that is below a .python-version file later does not raise the error either.

github-actions[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please let us know if this issue is still valid!