mirror of
https://github.com/github/codeql-action.git
synced 2026-01-06 22:50:17 +08:00
Improve experience when init fails before generating a config file
Suppose a customer has a run where the init Action failed before saving a config file. When the customer opens their Actions logs, the UI currently focuses on the post init step, since this is the last step that failed. Demoting the error in the post init Action to a warning means that the UI will instead focus on the `init` step, which is more useful for debugging what went wrong.
This commit is contained in:
@@ -13,8 +13,8 @@ export async function run(
|
||||
|
||||
const config = await getConfig(actionsUtil.getTemporaryDirectory(), logger);
|
||||
if (config === undefined) {
|
||||
throw new Error(
|
||||
"Config file could not be found at expected location. Did the 'init' action fail to start?"
|
||||
logger.warning(
|
||||
"Debugging artifacts are unavailable since the 'init' Action failed before it could produce any."
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user