Ignore snapshot_warnings for missing head snapshots
This commit is contained in:
+8
@@ -910,6 +910,14 @@ function addScannedDependencies(changes) {
|
||||
}
|
||||
exports.addScannedDependencies = addScannedDependencies;
|
||||
function addSnapshotWarnings(warnings) {
|
||||
// For now, we want to ignore warnings that just complain
|
||||
// about missing snapshots on the head SHA. This is a product
|
||||
// decision to avoid presenting warnings to users who simply
|
||||
// don't use snapshots.
|
||||
const ignore_regex = new RegExp(/No.*snapshot.*found.*head.*/, 'i');
|
||||
if (ignore_regex.test(warnings)) {
|
||||
return;
|
||||
}
|
||||
core.summary.addHeading('Snapshot Warnings', 2);
|
||||
core.summary.addQuote(`${icons.warning}: ${warnings}`);
|
||||
core.summary.addRaw('See the documentation for troubleshooting help.');
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -216,6 +216,15 @@ export function addScannedDependencies(changes: Changes): void {
|
||||
}
|
||||
|
||||
export function addSnapshotWarnings(warnings: string): void {
|
||||
// For now, we want to ignore warnings that just complain
|
||||
// about missing snapshots on the head SHA. This is a product
|
||||
// decision to avoid presenting warnings to users who simply
|
||||
// don't use snapshots.
|
||||
const ignore_regex = new RegExp(/No.*snapshot.*found.*head.*/, 'i')
|
||||
if (ignore_regex.test(warnings)) {
|
||||
return
|
||||
}
|
||||
|
||||
core.summary.addHeading('Snapshot Warnings', 2)
|
||||
core.summary.addQuote(`${icons.warning}: ${warnings}`)
|
||||
core.summary.addRaw('See the documentation for troubleshooting help.')
|
||||
|
||||
Reference in New Issue
Block a user