Skip to content

Commit dc278f5

Browse files
committed
Promisify'd child_process.execFile throws if exit code is non-zero
1 parent adf96f7 commit dc278f5

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

server/src/incrementalCompilation.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -712,7 +712,12 @@ async function compileContents(
712712
entry.project.bscBinaryLocation,
713713
callArgs,
714714
{ cwd, signal },
715-
);
715+
).catch((error) => {
716+
if (error.stderr) {
717+
return { stderr: error.stderr };
718+
}
719+
throw error;
720+
});
716721

717722
getLogger().log(
718723
`Recompiled ${entry.file.sourceFileName} in ${

0 commit comments

Comments
 (0)