mirror of
https://github.com/dense-analysis/ale.git
synced 2025-12-08 13:34:46 +08:00
Skip empty or unparseable ruff items
This commit is contained in:
@@ -76,6 +76,10 @@ function! ale_linters#python#ruff#Handle(buffer, lines) abort
|
|||||||
continue
|
continue
|
||||||
endtry
|
endtry
|
||||||
|
|
||||||
|
if empty(l:item)
|
||||||
|
continue
|
||||||
|
endif
|
||||||
|
|
||||||
if (l:item.code is# 'W291' || l:item.code is# 'W293')
|
if (l:item.code is# 'W291' || l:item.code is# 'W293')
|
||||||
\&& !ale#Var(a:buffer, 'warn_about_trailing_whitespace')
|
\&& !ale#Var(a:buffer, 'warn_about_trailing_whitespace')
|
||||||
" Skip warnings for trailing whitespace if the option is off.
|
" Skip warnings for trailing whitespace if the option is off.
|
||||||
|
|||||||
Reference in New Issue
Block a user