Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(logs): warn when Package lookup failures occur #23247

Merged
merged 1 commit into from Jul 7, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 4 additions & 4 deletions lib/workers/repository/errors-warnings.ts
Expand Up @@ -55,6 +55,9 @@ function getDepWarnings(
}
}
}
if (warnings.length) {
logger.warn({ warnings, files: warningFiles }, 'Package lookup failures');
}
return { warnings, warningFiles };
}

Expand All @@ -70,7 +73,6 @@ export function getDepWarningsOnboardingPR(
if (!warnings.length) {
return '';
}
logger.debug({ warnings, warningFiles }, 'Found package lookup warnings');
warningText = emojify(
`\n---\n\n### :warning: Dependency Lookup Warnings :warning:\n\n`
);
Expand All @@ -90,15 +92,14 @@ export function getDepWarningsPR(
config: RenovateConfig,
dependencyDashboard?: boolean
): string {
const { warnings, warningFiles } = getDepWarnings(packageFiles);
const { warnings } = getDepWarnings(packageFiles);
if (config.suppressNotifications?.includes('dependencyLookupWarnings')) {
return '';
}
let warningText = '';
if (!warnings.length) {
return '';
}
logger.debug({ warnings, warningFiles }, 'Found package lookup warnings');
warningText = emojify(
`\n---\n\n### :warning: Dependency Lookup Warnings :warning:\n\n`
);
Expand Down Expand Up @@ -130,7 +131,6 @@ export function getDepWarningsDashboard(
.map((dep) => '`' + dep + '`')
.join(', ');

logger.debug({ warnings, warningFiles }, 'Found package lookup warnings');
let warningText = emojify(
`\n---\n\n### :warning: Dependency Lookup Warnings :warning:\n\n`
);
Expand Down