Skip to content

Commit c6cad94

Browse files
committed
Nick: errors -> warn
1 parent 7ec278a commit c6cad94

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

apps/api/src/scraper/WebScraper/crawler.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ export class WebCrawler {
456456
}
457457
}).filter(x => x !== null) as string[])];
458458
} catch (error) {
459-
this.logger.error("Failed to call html-transformer! Falling back to cheerio...", {
459+
this.logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
460460
error,
461461
module: "scrapeURL", method: "extractMetadata"
462462
});

apps/api/src/scraper/scrapeURL/lib/extractLinks.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export async function extractLinks(html: string, baseUrl: string): Promise<strin
4141
try {
4242
return await extractLinksRust(html, baseUrl);
4343
} catch (error) {
44-
logger.error("Failed to call html-transformer! Falling back to cheerio...", {
44+
logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
4545
error,
4646
module: "scrapeURL", method: "extractLinks"
4747
});

apps/api/src/scraper/scrapeURL/lib/extractMetadata.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ export async function extractMetadata(
2626
try {
2727
return await extractMetadataRust(meta, html);
2828
} catch (error) {
29-
meta.logger.error("Failed to call html-transformer! Falling back to cheerio...", {
29+
meta.logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
3030
error,
3131
module: "scrapeURL", method: "extractMetadata"
3232
});

apps/api/src/scraper/scrapeURL/lib/removeUnwantedElements.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ export const htmlTransform = async (
6565
only_main_content: scrapeOptions.onlyMainContent,
6666
})
6767
} catch (error) {
68-
logger.error("Failed to call html-transformer! Falling back to cheerio...", {
68+
logger.warn("Failed to call html-transformer! Falling back to cheerio...", {
6969
error,
7070
module: "scrapeURL", method: "extractLinks"
7171
});

0 commit comments

Comments
 (0)