File tree Expand file tree Collapse file tree 1 file changed +24
-10
lines changed Expand file tree Collapse file tree 1 file changed +24
-10
lines changed Original file line number Diff line number Diff line change @@ -91,16 +91,30 @@ def find_errors(self, output):
9191 for line in data ["Report" ]["Error" ].splitlines ():
9292 if line .count (":" ) < 3 :
9393 continue
94- parts = line .split (":" )
95- data ["Issues" ].append ({
96- "FromLinter" : "typecheck" ,
97- "Text" : parts [3 ].strip (),
98- "Pos" : {
99- "Filename" : parts [0 ],
100- "Line" : parts [1 ],
101- "Column" : parts [2 ],
102- }
103- })
94+ if line .startswith ("typechecking error: " ):
95+ line = line [20 :]
96+ if line [1 :3 ] == ":\\ " : # windows path in filename
97+ parts = line .split (":" , 4 )
98+ data ["Issues" ].append ({
99+ "FromLinter" : "typecheck" ,
100+ "Text" : parts [4 ].strip (),
101+ "Pos" : {
102+ "Filename" : ':' .join (parts [0 :2 ]),
103+ "Line" : parts [2 ],
104+ "Column" : parts [3 ],
105+ }
106+ })
107+ else :
108+ parts = line .split (":" , 3 )
109+ data ["Issues" ].append ({
110+ "FromLinter" : "typecheck" ,
111+ "Text" : parts [3 ].strip (),
112+ "Pos" : {
113+ "Filename" : parts [0 ],
114+ "Line" : parts [1 ],
115+ "Column" : parts [2 ],
116+ }
117+ })
104118
105119 """find relevant issues and yield a LintMatch"""
106120 if data and "Issues" in data :
You can’t perform that action at this time.
0 commit comments