1

I am using SpaceVim 1.0.0-dev with the following layers in my config:

[[layers]]
name = 'autocomplete'
auto-completion-return-key-behavior = "complete"
auto-completion-tab-key-behavior = "cycle"

[[layers]]
name = 'shell'
default_position = 'top'
default_height = 30

[[layers]]
name = 'lsp'
filetypes = ["python"]

[[layers]]
name = 'unite'

[[layers]]
name = 'git'

[[layers]]
name = 'lang#python'

[[layers]]
name = 'lang#markdown'

I tried supressing the line-too-long warning with

# noqa: E501
# pylint: disable=line-too-long

towards the top of the source file, but it does not work. I am very new to SpaceVim, and very confused by the whole layers thing... I cannot even find out which linter is used (although i suspect that pylint is used).

Any pointer would be greatly appreciated.

  • 1
    As a new comer to Vim I strongly encourage you not to use SpaceVim and instead build your own config which matches your actual needs: you will learn much more about vim and will save a lot of time debugging weird and complex configs you don't understand. Now to actually solve your problem you should ask your question on their issue tracker there you'll get answers from people who actually made the tool and know how it works so you should get better and faster answers. – statox Nov 22 '18 at 13:41
  • This has actually nothing to do with vim. Pylint ist a python linter, which has its own .pylintrc. file. Have a look here: stackoverflow.com/questions/4341746/… – Doktor OSwaldo Nov 22 '18 at 14:15
  • 1
    Thank you both for your suggestions. statox: I will look into the issue tracker. Doktor OSwaldo: my .pylintrc contains some adjustments that are ignored by the messages in vim (neovim to be specific), which is why I am trying to find out what is happening – bjoernz Nov 22 '18 at 15:21
0

In SpaceVim, the default layer contains checkers layer which is using neomake, you can read :h neomake to config your pylint maker.

in neomake the default pylint confg is:

function! neomake#makers#ft#python#pylint() abort
    let maker = {
        \ 'args': [
            \ '--output-format=text',
            \ '--msg-template="{path}:{line}:{column}:{C}: [{symbol}] {msg} [{msg_id}]"',
            \ '--reports=no'
        \ ],
        \ 'errorformat':
            \ '%A%f:%l:%c:%t: %m,' .
            \ '%A%f:%l: %m,' .
            \ '%A%f:(%l): %m,' .
            \ '%-Z%p^%.%#,' .
            \ '%-G%.%#',
        \ 'output_stream': 'stdout',
        \ 'postprocess': [
        \   function('neomake#postprocess#generic_length'),
        \   function('neomake#makers#ft#python#PylintEntryProcess'),
        \ ]}
    function! maker.filter_output(lines, context) abort
        if a:context.source ==# 'stderr'
            call filter(a:lines, "v:val !=# 'No config file found, using default configuration' && v:val !~# '^Using config file '")
        endif
        call neomake#makers#ft#python#FilterPythonWarnings(a:lines, a:context)
    endfunction
    return maker
endfunction

make sure you have .pylintrc in your project root or home dir.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.