8000 KeyError: 'pylint' · Issue #783 · python-mode/python-mode · GitHub
[go: up one dir, main page]

Skip to content

KeyError: 'pylint' #783

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
zeraus opened this issue Jul 29, 2017 · 11 comments
Closed

KeyError: 'pylint' #783

zeraus opened this issue Jul 29, 2017 · 11 comments

Comments

@zeraus
Copy link
zeraus commented Jul 29, 2017

Hello! I'm using Neovim and I got this message when I save the file at first, and then if I check with :PymodeLint
I've installed pylint with pip, pip install pylint

Imgur

Pymode diagnostic
===================
VIM:704, OS: Darwin, multi_byte:1, pymode: 0.9.2, pymode-python: python3


+python: 0
+python3: 1

VIM python paths:
-----------------
/Users/xnu/workspace/automate-the-boring-stuff
/Users/xnu/.local/share/nvim/plugged/python-mode/pymode/libs
/Users/xnu/.local/share/nvim/plugged/python-mode
/Users/xnu/.local/share/nvim/plugged/jedi-vim
/usr/local/Cellar/python3/3.6.2/Frameworks/Python.framework/Versions/3.6/lib/python36.zip
/usr/local/Cellar/python3/3.6.2/Frameworks/Python.framework/Versions/3.6/lib/python3.6
/usr/local/Cellar/python3/3.6.2/Frameworks/Python.framework/Versions/3.6/lib/python3.6/lib-dynload
/usr/local/lib/python3.6/site-packages
_vim_path_
/Users/xnu/.local/share/nvim/plugged/python-mode/pymode/libs/astroid/brain

Pymode variables:
-------------------
let pymode = 1
let pymode_breakpoint = 1
let pymode_breakpoint_bind = '<leader>b'
let pymode_doc = 1
let pymode_doc_bind = 'K'
let pymode_folding = 1
let pymode_indent = 1
let pymode_lint = 1
let pymode_lint_checkers = ['pyflakes', 'pep8', 'mccabe']
let pymode_lint_cwindow = 1
let pymode_lint_ignore = ''
let pymode_lint_message = 1
let pymode_lint_on_fly = 0
let pymode_lint_on_write = 1
let pymode_lint_select = ''
let pymode_lint_signs = 1
let pymode_motion = 1
let pymode_options = 1
let pymode_paths = []
let pymode_quickfix_maxheight = 6
let pymode_quickfix_minheight = 3
let pymode_rope = 0
let pymode_run = 1
let pymode_run_bind = '<leader>r'
let pymode_trim_whitespaces = 1
let pymode_virtualenv = 1
let pymode_virtualenv_enabled = ''
let pymode_virtualenv_path = ''

========================================
Python related plugins and configurations from init.vim:

"" Plugins
Plug 'klen/python-mode', { 'for': 'python' }
Plug 'davidhalter/jedi-vim', { 'for': 'python' }
Plug 'zchee/deoplete-jedi', { 'for': 'python' }

"" Python
let g:python_host_prog = '/usr/local/bin/python2'
let g:python3_host_prog  = '/usr/local/bin/python3'

" Skip the check of neovim module
let g:python3_host_skip_check = 1
let g:loaded_python_provider = 1

" Avoid jedi-vim's Py2-not-functional message
let g:jedi#force_py_version = 3

"" pymode (fix PymodeRopeRegenerate)
let g:pymode_rope = 0

What I'm doing wrong?
Please help me and also let me know if I left information to provide.

@zeraus
Copy link
Author
zeraus commented Jul 29, 2017

Same with #775, #774.
Sorry, a little confused here. Is it fixed or not yet?

@qwexvf
Copy link
qwexvf commented Aug 6, 2017

Hello, i dont know why they still keep that fix in the master branch but you can switch to develop branch to get the fix.
if your using vim-plug for example

Plug 'python-mode/python-mode', {'branch': 'develop'}

Something like this.
Good luck sir.

@zeraus
Copy link
Author
zeraus commented Aug 8, 2017

Hi @qwexvf, thanks for the answer. It's fixed somehow after last update.
I will try as you guided if I got it next time.
Again, thank you!

@eleijonmarck
Copy link

I still get same problem. It appears everytime. It is very annoying :(

@diraol
Copy link
Contributor
diraol commented Nov 1, 2017

@eleijonmarck you may need to clear the cache/compiled files:

#777 (comment)

@eleijonmarck
Copy link

Thanks that worked

@cuducos
Copy link
cuducos commented Mar 1, 2019

I'm still having this issue. I'm using a brand new computer (formatted yesterday, reinstalled the OS), and even cleaning __pycache__ and *.pyc the error pops in.

Is changing options.linters_params['pylint'] by something options.linters_params.get('pylint') a valid solution? Why?

@diraol
Copy link
Contributor
diraol commented Mar 7, 2019

Hi @cuducos !

where exactly are you proposing to make this change?

@cuducos
Copy link
cuducos commented Mar 7, 2019

where exactly are you proposing to make this change?

Hum… ok, my bad. I should have better studied the way branches and releases work in this repo. Let me try to clarify. The error I'm getting is as follows:

screen shot 2019-03-01 at 10 01 41

However, now I see that this code is not present at the develop branch anymore. Thus I'm not sure if it still makes sense to do what I was planning to do, which was to use .get on the dictionary to avoid the KeyError

@diraol
Copy link
Contributor
diraol commented Mar 7, 2019

No problem! You were probably using the master branch and, indeed, our current maintained working branch is the develop.

Take a look to see if it works if you change to the develop branch, please. ;)

@cuducos
Copy link
cuducos commented Mar 7, 2019

Take a look to see if it works if you change to the develop branch, please.

Indeed: worked like a charm. Many thanks : )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants
0