Remove validation failures and warning annotations (#108)

* Update warnings behavior

* Add void return type
This commit is contained in:
Josh Gross
2019-11-21 14:37:54 -05:00
committed by GitHub
parent 639f9d8b81
commit 95c1798369
8 changed files with 82 additions and 40 deletions

View File

@@ -10,13 +10,14 @@ async function run(): Promise<void> {
try {
// Validate inputs, this can cause task failure
if (!utils.isValidEvent()) {
core.setFailed(
utils.logWarning(
`Event Validation Error: The event type ${
process.env[Events.Key]
} is not supported. Only ${utils
.getSupportedEvents()
.join(", ")} events are supported at this time.`
);
return;
}
const cachePath = utils.resolvePath(
@@ -118,7 +119,7 @@ async function run(): Promise<void> {
`Cache restored from key: ${cacheEntry && cacheEntry.cacheKey}`
);
} catch (error) {
core.warning(error.message);
utils.logWarning(error.message);
utils.setCacheHitOutput(false);
}
} catch (error) {