Nick: errors -> warn

This commit is contained in:
Nicolas 2025-03-13 13:07:51 -04:00
parent 7ec278a908
commit c6cad942ab
4 changed files with 4 additions and 4 deletions

View File

@ -456,7 +456,7 @@ export class WebCrawler {
} }
}).filter(x => x !== null) as string[])]; }).filter(x => x !== null) as string[])];
} catch (error) { } catch (error) {
this.logger.error("Failed to call html-transformer! Falling back to cheerio...", { this.logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
error, error,
module: "scrapeURL", method: "extractMetadata" module: "scrapeURL", method: "extractMetadata"
}); });

View File

@ -41,7 +41,7 @@ export async function extractLinks(html: string, baseUrl: string): Promise<strin
try { try {
return await extractLinksRust(html, baseUrl); return await extractLinksRust(html, baseUrl);
} catch (error) { } catch (error) {
logger.error("Failed to call html-transformer! Falling back to cheerio...", { logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
error, error,
module: "scrapeURL", method: "extractLinks" module: "scrapeURL", method: "extractLinks"
}); });

View File

@ -26,7 +26,7 @@ export async function extractMetadata(
try { try {
return await extractMetadataRust(meta, html); return await extractMetadataRust(meta, html);
} catch (error) { } catch (error) {
meta.logger.error("Failed to call html-transformer! Falling back to cheerio...", { meta.logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
error, error,
module: "scrapeURL", method: "extractMetadata" module: "scrapeURL", method: "extractMetadata"
}); });

View File

@ -65,7 +65,7 @@ export const htmlTransform = async (
only_main_content: scrapeOptions.onlyMainContent, only_main_content: scrapeOptions.onlyMainContent,
}) })
} catch (error) { } catch (error) {
logger.error("Failed to call html-transformer! Falling back to cheerio...", { logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
error, error,
module: "scrapeURL", method: "extractLinks" module: "scrapeURL", method: "extractLinks"
}); });