Web Scraper avatar

Web Scraper

Try for free

No credit card required

Go to Store
Web Scraper

Web Scraper

apify/web-scraper
Try for free

No credit card required

Crawls arbitrary websites using the Chrome browser and extracts structured data from web pages using a provided JavaScript function. The Actor supports both recursive crawling and lists of URLs, and automatically manages concurrency for maximum performance.

CR

container error.

Closed
caravel opened this issue
20 days ago

lore@LAPTOP-EOOJ6UJ0:~$ docker ps permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get "http://%2Fvar%2Frun%2Fdocker.sock/v1.47/containers/json": dial unix /var/run/docker.sock: connect: permission denied

jindrich.bar avatar

Hello Caravel and thank you for your input!

The preNavigationHooks option expects a JavaScript array as a string (starting with [ and ending with ]). The module.exports part is unnecessary and is causing the compilation error — removing it should resolve the issue in your run.

Additionally, the Actor already applies some fingerprint obfuscation internally. Overwriting properties like the user-agent string may create inconsistencies and make detection by anti-scraping tools easier.

It's also important to note that preNavigationHooks run before the browser loads the page. While this is a good time e.g. to modify request headers, handling cookie banners or detecting captchas won't work here since the page content hasn’t loaded yet. You may want to move that logic to postNavigationHooks.

I'll be closing this issue. Feel free to open a new one if you need further assistance.

Developer
Maintained by Apify

Actor Metrics

  • 3.3k monthly users

  • 456 bookmarks

  • >99% runs succeeded

  • 4.8 days response time

  • Created in Mar 2019

  • Modified a month ago