question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Navigation Timeout Exceeded when trying to load a http resource that is probably blocked by provider

See original GitHub issue

Steps to reproduce

Tell us about your environment:

  • Puppeteer version: 1.16.0
  • Platform / OS version: macOS 10.14.5
  • URLs (if applicable):
  • Node.js version: 11.9.0

What steps will reproduce the problem?

const browser = await puppeteer.launch();
const page = await browser.newPage();
await page.goto('http://www.alitalia.com/etc/designs/alitalia/clientlibs-1/images/logo.png');
const pdf = await page.pdf({
    format: 'A4',
    margin: {
        top: '1cm',
        bottom: '1cm',
        left: '1cm',
        right: '1cm'
    }
});
await browser.close();

What is the expected result? A Pdf from the logo or a clearer error message.

What happens instead?

{ TimeoutError: Navigation Timeout Exceeded: 30000ms exceeded
    at Promise.then (/Users/leon/Documents/Lambus/mail-test/node_modules/puppeteer/lib/LifecycleWatcher.js:142:21)
  -- ASYNC --
    at Frame.<anonymous> (/Users/leon/Documents/Lambus/mail-test/node_modules/puppeteer/lib/helper.js:110:27)
    at Page.goto (/Users/leon/Documents/Lambus/mail-test/node_modules/puppeteer/lib/Page.js:629:49)
    at Page.<anonymous> (/Users/leon/Documents/Lambus/mail-test/node_modules/puppeteer/lib/helper.js:111:23)
    at Promise (/Users/leon/Documents/Lambus/mail-test/test/test.js:21:24)
    at processTicksAndRejections (internal/process/next_tick.js:81:5) name: 'TimeoutError' }

Additional informations I discovered this error because I tried to load a resource from alitalia, for example the logo. If this resource is included via http, puppeteer runs into a timeout. If I include the resource via https, there is no timeout, but the logo is not printed. Also this issue seems only happening in headless mode.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
Abolfazl2647commented, Aug 17, 2020

i have react snap and in beta there is no issue but as soon as i merge beta into master for production build i’m getting this error

$ react-snap
 ️️️💬  console.log at /: This script won't run on localhost
 🔥  error at / TimeoutError: Navigation Timeout Exceeded: 30000ms exceeded
     at /app/node_modules/puppeteer/lib/LifecycleWatcher.js:142:21
   -- ASYNC --
     at Frame.<anonymous> (/app/node_modules/puppeteer/lib/helper.js:111:15)
     at Page.goto (/app/node_modules/puppeteer/lib/Page.js:674:49)
     at Page.<anonymous> (/app/node_modules/puppeteer/lib/helper.js:112:23)
     at fetchPage (/app/node_modules/react-snap/src/puppeteer_utils.js:232:22)
     at processTicksAndRejections (internal/process/task_queues.js:97:5)
 error Command failed with exit code 1.
 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
 The command '/bin/sh -c yarn build' returned a non-zero code: 1
Running after_script
00:01
Uploading artifacts for failed job
00:01
 ERROR: Job failed: exit code 1

beta and production have same environment

0reactions
stale[bot]commented, Jul 26, 2022

We are closing this issue. If the issue still persists in the latest version of Puppeteer, please reopen the issue and update the description. We will try our best to accomodate it!

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to solve Puppeteer TimeoutError: Navigation timeout of ...
One of the most usual problems with pages that contain a lot of content, because of the ads, images etc. is the load...
Read more >
Webscraping TimeoutError: Navigation timeout of 30000 ms ...
By default, the maximum navigation timeout is 30 seconds. If for some reason, your target url requires more time to load (which seems...
Read more >
How to Fix the 504 Gateway Timeout Error on Your Site - Kinsta
HTTP timeouts can occur when a connection between the web server and the client is kept open for too long. With WordPress sites,...
Read more >
Troubleshoot Azure Cosmos DB forbidden exceptions
The HTTP status code 403 represents the request is forbidden to complete. Firewall blocking requests. Data plane requests can come to Azure ...
Read more >
Force HTTPS with .htaccess for Security | InMotion Hosting
Please be sure that you can connect to your site over SSL and try again. Error Returned: Navigation Timeout Exceeded: 30000ms exceeded.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found