JSDOMCrawler, website breaks crawlee
Hey, after im getting a Warning the whole process stops, is it possible to catch it? WARN JSDOMCrawler: Reclaiming failed request back to the list or queue. ReferenceError: request is not defined
at JSDOMCrawler.requestHandler (/home/vue/repo/test/fofo.js:14:31)
at /home/vue/repo/test/node_modules/@crawlee/http/internals/http-crawler.js:336:81
at wrap (/home/vue/repo/test/node_modules/@apify/timeout/index.js:52:27)
at /home/vue/repo/test/node_modules/@apify/timeout/index.js:66:7
at AsyncLocalStorage.run (node:async_hooks:319:14)
at /home/vue/repo/test/node_modules/@apify/timeout/index.js:65:13
at new Promise (<anonymous>)
at addTimeoutToPromise (/home/vue/repo/test/node_modules/@apify/timeout/index.js:59:10)
at JSDOMCrawler._runRequestHandler (/home/vue/repo/test/node_modules/@crawlee/http/internals/http-crawler.js:336:53)
at runMicrotasks (<anonymous>) {"id":"AbgRUNVvKFwQD3K","url":"https://mmmiyama.com","retryCount":1}
2 Replies
like-goldOP•2y ago
A example would be never getting Crawler finished
absent-sapphire•2y ago
It says
request is not defined
You need to get it from CrawlingContext
(https://crawlee.dev/api/next/core/interface/CrawlingContext#request)