Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add error messaging to user when Kani crashes during coverage #132

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/format-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:

- name: Check TS linting
run: |
npm install -g npm@latest
npm install -g npm@9.8
npm install
npm run lint

Expand Down
8 changes: 7 additions & 1 deletion src/ui/coverage/coverageInfo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,13 @@ async function runCoverageCommand(command: string, harnessName: string): Promise

vscode.window.showInformationMessage(`Generating coverage for ${harnessName}`);
return new Promise((resolve, _reject) => {
execFile(kaniBinaryPath, args, options, async (_error: any, stdout: any, _stderr: any) => {
execFile(kaniBinaryPath, args, options, async (error: any, stdout: any, stderr: any) => {

// Check for compilation errors from Kani
if(stderr && stderr.includes('error: could not compile')) {
vscode.window.showInformationMessage(`Kani had errors during compilation to following errors: \n${stdout}`);
}

if (stdout) {
const parseResult = await parseKaniCoverageOutput(stdout);
resolve({ statusCode: 0, result: parseResult });
Expand Down
Loading