mirror of
https://github.com/github/codeql-action.git
synced 2026-04-26 16:58:47 +00:00
Use getErrorMessage in log too
This commit is contained in:
@@ -231,7 +231,7 @@ test("Don't crash if uploading a database fails", async (t) => {
|
||||
(v) =>
|
||||
v.type === "warning" &&
|
||||
v.message ===
|
||||
"Failed to upload database for javascript: Error: some error message",
|
||||
"Failed to upload database for javascript: some error message",
|
||||
) !== undefined,
|
||||
);
|
||||
});
|
||||
|
||||
@@ -138,7 +138,9 @@ export async function cleanupAndUploadDatabases(
|
||||
}
|
||||
} catch (e) {
|
||||
// Log a warning but don't fail the workflow
|
||||
logger.warning(`Failed to upload database for ${language}: ${e}`);
|
||||
logger.warning(
|
||||
`Failed to upload database for ${language}: ${util.getErrorMessage(e)}`,
|
||||
);
|
||||
reports.push({
|
||||
language,
|
||||
error: util.getErrorMessage(e),
|
||||
|
||||
Reference in New Issue
Block a user