magesuite / magepack

Next generation Magento 2 advanced JavaScript bundler.
Open Software License 3.0
438 stars 91 forks source link

Detect and alert on HTTP errors #168

Open fredden opened 2 years ago

fredden commented 2 years ago

Fixes #71 Closes #143


Before (~32.5 seconds):

ℹ Collecting bundle modules in the browser.
ℹ Collecting modules for bundle "cms".

 ERROR  waiting for function failed: timeout 30000ms exceeded

  at new WaitTask (node_modules/puppeteer/lib/DOMWorld.js:549:28)
  at DOMWorld.waitForFunction (node_modules/puppeteer/lib/DOMWorld.js:454:12)
  at Frame.waitForFunction (node_modules/puppeteer/lib/FrameManager.js:657:28)
  at Page.waitForFunction (node_modules/puppeteer/lib/Page.js:1141:29)
  at module.exports (lib/generate/collectModules.js:10:16)
  at Object.cms (lib/generate/collector/cms.js:38:39)
  at processTicksAndRejections (internal/process/task_queues.js:97:5)
  at async module.exports (lib/generate.js:28:13)

After (~2.5 seconds):

ℹ Collecting bundle modules in the browser.
ℹ Collecting modules for bundle "cms".
ℹ Requested http://example.com/ but navigation ended on https://www.example.com/

 ERROR  HTTP status code 503 returned from https://www.example.com/

  at module.exports (lib/generate/createPage.js:36:19)
  at processTicksAndRejections (internal/process/task_queues.js:97:5)
  at async Object.cms (lib/generate/collector/cms.js:29:18)
  at async module.exports (lib/generate.js:28:13)
fredden commented 1 year ago

@krzksz is there anything I can do to help get this merged in?