upgrading dependencies / new pois

This commit is contained in:
orangecoding
2026-05-11 09:18:32 +02:00
parent 6816b0aded
commit 8b012ef2f1
7 changed files with 119 additions and 55 deletions

View File

@@ -7,6 +7,8 @@ import { launch } from 'cloakbrowser/puppeteer';
import { debug, botDetected } from './utils.js';
import { getPreLaunchConfig } from './botPrevention.js';
import logger from '../logger.js';
import { trackPoi } from '../tracking/Tracker.js';
import { TRACKING_POIS } from '../../TRACKING_POIS.js';
/**
* Launch a CloakBrowser/Puppeteer browser instance with stealth and humanizer enabled.
@@ -145,6 +147,9 @@ export default async function execute(url, waitForSelector, options) {
if (botDetected(pageSource, statusCode)) {
logger.warn('We have been detected as a bot :-/ Tried url: => ', url);
await trackPoi(TRACKING_POIS.DETECTED_AS_BOT);
result = null;
} else {
result = pageSource || (await page.content());