Skip to content
Snippets Groups Projects
Commit 964dc608 authored by SeeBasTStick's avatar SeeBasTStick
Browse files

removed print statements

parent de7da51a
No related branches found
No related tags found
No related merge requests found
......@@ -62,10 +62,8 @@ export function buildErrors(errorLines : Array<string> ): Map<string, Set<NDJSON
*/
export function matchErrors(infos: Set<NDJSON>, file?: TextDocument | undefined): Array<Diagnostic> {
let result: Array<Diagnostic> = new Array()
console.log("infos " + infos)
for (var info of infos) {
console.log("type" + info.type)
let serveity: DiagnosticSeverity = DiagnosticSeverity.Error
if (info.type == "error") {
......@@ -131,8 +129,6 @@ export interface NDJSON {
start: StartOrEnd
end: StartOrEnd
prob_version : string
// main_file : string
// dependencies : Array<string>
}
......
......@@ -175,8 +175,8 @@ async function validateTextDocument(textDocument: TextDocument): Promise<void> {
let documentPath: path.ParsedPath = path.parse(URI.parse(textDocument.uri).path);
let errorDic : string = documentPath.dir + '/tmp'
let errorPath: string = errorDic + '/_error.json'
let errorDic : string = documentPath.dir + path.sep + 'tmp'
let errorPath: string = errorDic + path.sep + '_error.json'
const { exec } = require('child_process');
......@@ -206,19 +206,13 @@ async function validateTextDocument(textDocument: TextDocument): Promise<void> {
for(let dependency of allFilesAndCorrespondingErrors.keys())
{
console.log(dependency)
console.log(documentPath.dir+documentPath.name+documentPath.ext)
if(dependency == (documentPath.dir+documentPath.name+documentPath.ext)){
console.log("is:main")
if(dependency == (documentPath.dir+ path.sep + documentPath.name+documentPath.ext)){
let errors : Set<NDJSON> = allFilesAndCorrespondingErrors.get(dependency)!!
console.log("errors " + errors)
let diagnostics = matchErrors(errors, textDocument)
connection.sendDiagnostics({ uri: dependency, diagnostics });
}else{
console.log("is:dep")
let errors : Set<NDJSON> = allFilesAndCorrespondingErrors.get(dependency)!!
let diagnostics = matchErrors(errors)
console.log("errors " + errors)
connection.sendDiagnostics({ uri: dependency, diagnostics });
}
}
......@@ -227,7 +221,6 @@ async function validateTextDocument(textDocument: TextDocument): Promise<void> {
for(let dependency of filesToReset)
{
console.log("reset:errrors")
let diagnostics : Array<Diagnostic> = new Array()
connection.sendDiagnostics({ uri: dependency, diagnostics });
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment