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 data from pages using JavaScript code. The Actor supports both recursive crawling and lists of URLs and automatically manages concurrency for maximum performance. This is Apify's basic tool for web crawling and scraping.

Do you want to learn more about this Actor?

Get a demo
RS

The main function of the Actor threw an exception.

Closed

ritzy_sample opened this issue
4 months ago

Hi,

I don't know what is causing this issue as I am quite new to scraping.

The result I am getting is this: ERROR Compilation of pageFunction failed.

Appreciate any help

jindrich.bar avatar

Hello, and thank you for your interest in this Actor!

The logs of your Actor say it all. Under the ERROR Compilation of pageFunction failed. line, the Actor prints the exact error - which is Unexpected identifier: pageHtml in your case. On the Input tab, the pageFunction editor also checks for syntax errors - you can see that you've missed a comma after the second-last line (see the attached screenshot).

I tried adding that one comma and the Actor worked as expected, returning two results.

I'll close this issue now, but feel free to ask additional questions if you have any. Cheers!

Developer
Maintained by Apify

Actor Metrics

  • 2.4k monthly users

  • 278 stars

  • >99% runs succeeded

  • 38 days response time

  • Created in Mar 2019

  • Modified 4 months ago