From 01353add63518a3b3fff9ed18475f28a5753942d Mon Sep 17 00:00:00 2001 From: Jackson Harper Date: Tue, 5 Jul 2022 11:16:09 -0700 Subject: [PATCH] Shorten the timeout requesting pages I believe our process is sometimes being terminated before this timeout is hit, which means we then don't have time to fetch with a fallback. --- packages/content-fetch/fetch-content.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/content-fetch/fetch-content.js b/packages/content-fetch/fetch-content.js index 33e5b9506..296215aa7 100644 --- a/packages/content-fetch/fetch-content.js +++ b/packages/content-fetch/fetch-content.js @@ -540,7 +540,7 @@ async function retrievePage(url) { }); try { - const response = await page.goto(url, { waitUntil: ['networkidle2'] }); + const response = await page.goto(url, { timeout: 8 * 1000, waitUntil: ['networkidle2'] }); const finalUrl = response.url(); const contentType = response.headers()['content-type'];