mattheworres / hootdraft-scraper

NodeJS-based scraper for player data in Hoot Draft
1 stars 0 forks source link

Fix US Pro Scrapes #11

Closed mattheworres closed 2 years ago

mattheworres commented 2 years ago

Data source CBS Sports recently revamped their stats pages, and rather than being able to go alphabetically, we now must go by team in order to scrape players.

Also have to do a bit of fun magic to not only generate the URL, but also flip the player name around as CBS no longer lists players as Last, First but now show players with First Last (which is fun for Juniors, III's as well as folks with spaces in their last name, like Mr. De La Cruz. He gets his own unit test case! :) )

Still need to test on/update for NCAA sports, but this at least works for the four major US sports (so, this does not fix #9 - yet! )

mattheworres commented 2 years ago

Got NCAA FB & BB working again, though the teams list is considerably smaller. Nothing I can do about that, but it all works. Switched from going alphabetically to just scraping by teams, which I already had the data structures to handle.