summaryrefslogtreecommitdiff
path: root/autoload
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2017-05-31 15:19:58 +0100
committerw0rp <devw0rp@gmail.com>2017-05-31 15:20:12 +0100
commit42efd517232c3f62289910e53f1d2fe2549196cf (patch)
tree14f1b5958d0a09ffe8c65e3b9a57c973a4f14a02 /autoload
parent5eb80f03a2d0831a1fc3b06790f634d7f2b09658 (diff)
downloadale-42efd517232c3f62289910e53f1d2fe2549196cf.zip
Fix #596 - Report exceptions thrown by flake8
Diffstat (limited to 'autoload')
-rw-r--r--autoload/ale/handlers/python.vim10
1 files changed, 10 insertions, 0 deletions
diff --git a/autoload/ale/handlers/python.vim b/autoload/ale/handlers/python.vim
index 952df8f4..419e262e 100644
--- a/autoload/ale/handlers/python.vim
+++ b/autoload/ale/handlers/python.vim
@@ -2,6 +2,16 @@
" Description: Error handling for flake8, etc.
function! ale#handlers#python#HandlePEP8Format(buffer, lines) abort
+ for l:line in a:lines[:10]
+ if match(l:line, '^Traceback') >= 0
+ return [{
+ \ 'lnum': 1,
+ \ 'text': 'An exception was thrown. See :ALEDetail',
+ \ 'detail': join(a:lines, "\n"),
+ \}]
+ endif
+ endfor
+
" Matches patterns line the following:
"
" Matches patterns line the following: