We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 00e0c10 commit 0ddfa44Copy full SHA for 0ddfa44
1 file changed
pyls/plugins/pyflakes_lint.py
@@ -35,6 +35,10 @@ def unexpectedError(self, filename, msg): # pragma: no cover
35
pass
36
37
def syntaxError(self, _filename, msg, lineno, offset, text):
38
+ # We've seen that lineno and offset can sometimes be None
39
+ lineno = lineno or 1
40
+ offset = offset or 0
41
+
42
err_range = {
43
'start': {'line': lineno - 1, 'character': offset},
44
'end': {'line': lineno - 1, 'character': offset + len(text)},
0 commit comments