[b]"What's the best way to build a web crawler in Python from scratch?"[/b] or [b]"How can I optimize my web crawl

22 Replies, 759 Views

"What's the best way to build a web crawler in Python from scratch?"

Hey folks!

I'm trying to build a web crawler python project from scratch. Not sure where to start—should I use `requests` + `BeautifulSoup` or go straight for Scrapy?

Also, how do you handle pagination and storing the data?

Any tips or example code would be awesome. Thanks!

---

OR

"How can I optimize my web crawler in Python for faster scraping?"

Yo!

My web crawler python script is kinda slow. Using `requests` and `bs4` rn, but it feels clunky.

Should I switch to async (like `aiohttp`)? Or maybe tweak the delay between requests?

Also, how do you guys manage proxies to avoid throttling?

Appreciate any hacks!

---

OR

"Any tips for handling JavaScript-heavy sites with a web crawler in Python?"

Ugh, JS sites are the worst for my web crawler python setup. `requests` just gets empty HTML.

Do I *have* to use Selenium or Playwright? Or is there a lighter workaround?

Kinda wanna avoid the overhead if possible.

Thoughts?

---

OR

"Is Scrapy still the best framework for a web crawler in Python?"

Scrapy fans—still worth it in 2024?

I’ve used it before, but wondering if something newer/simpler exists for web crawler python projects.

Or is Scrapy still king for large-scale scraping?

Lemme know your experiences!

---

OR

"How do you avoid getting blocked when running a web crawler in Python?"

My web crawler python keeps getting blocked after a few requests.

Using random headers and delays, but sites still detect me.

Proxies? Rotating user-agents? Or am I missing something?

Help a noob out!

Messages In This Thread
[b]"What's the best way to build a web crawler in Python from scratch?"[/b] or [b]"How can I optimize my web crawl - by - 01-03-2024, 12:05 AM



Users browsing this thread: 1 Guest(s)