Skip to content

Commit

Permalink
fix: Avoid excessive sendDiagnostic calls (#183)
Browse files Browse the repository at this point in the history
Signed-off-by: Arunprasad Rajkumar <[email protected]>
  • Loading branch information
arajkumar authored Feb 5, 2021
1 parent 88969e1 commit 158b1b1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions release.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ module.exports = {
{
path: "analytics-lsp-linux",
name: "analytics-lsp-linux",
label: "analytics-lsp-server"
label: "analytics-lsp-linux"
},
{
path: "analytics-lsp-macos",
Expand All @@ -44,7 +44,7 @@ module.exports = {
{
path: "analytics-lsp-linux.sha256",
name: "analytics-lsp-linux.sha256",
label: "analytics-lsp-server.sha256"
label: "analytics-lsp-linux.sha256"
},
{
path: "analytics-lsp-macos.sha256",
Expand Down
3 changes: 2 additions & 1 deletion src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,9 @@ function runPipeline(response, diagnostics, packageAggregator, diagnosticFilePat
totalCount.advisoryCount += secEng.advisoryCount;
totalCount.exploitCount += secEng.exploitCount;
}
connection.sendDiagnostics({ uri: diagnosticFilePath, diagnostics: diagnostics });
});
connection.sendDiagnostics({ uri: diagnosticFilePath, diagnostics: diagnostics });
connection.console.log(`sendDiagnostics: ${diagnostics?.length}`);
}

/* Slice payload in each chunk size of @batchSize */
Expand Down

0 comments on commit 158b1b1

Please sign in to comment.