grumpy-cyan
grumpy-cyan10mo ago

Max session count 1 doesn't work, session got called concurrently upon starting.

No description
No description
7 Replies
grumpy-cyan
grumpy-cyanOP10mo ago
No description
grumpy-cyan
grumpy-cyanOP10mo ago
upon starting the crawler, a single session got called 2 times even with maxUsageCount = 1
grumpy-cyan
grumpy-cyanOP10mo ago
well even with max concurrency 1, the session get reused on the next request
No description
grumpy-cyan
grumpy-cyanOP10mo ago
when i explicitly retire the session in preNavHook, the same session still gets called twice
No description
grumpy-cyan
grumpy-cyanOP10mo ago
GitHub
SessionPool generates more sessions that needed and also does not r...
Which package is this bug report for? If unsure which one to select, leave blank None Issue description Create basic PlaywrightCrawler/PuppeteerCrawler/HttpCrawler (at least I've tried all thes...
lemurio
lemurio10mo ago
hey, thanks for reporting. For now, to make it work, you can set maxUsageCount in the createSessionFunction when creating the session
grumpy-cyan
grumpy-cyanOP10mo ago
i got it working by keeping track of usageCount inside the router handler, the state is stored separately on request.session.userData

Did you find this page helpful?