So The Onion’s new owners have updated the site, moving it over to Wordpress (it’s actually a lot nicer now), but that in turn has broken this bot. Everything else works other than the scraper. Issues seem to be:

  1. The bot goes to https://theonion.com/latest which doesn’t exist anymore, I’d say it’d make sense to have it grab the top headline from the homepage instead since it only posts once a day anyway.

  2. It’s grabbing the wrong link, not sure 100% what it’s doing but it might be grabbing the new link in the top left corner of the website that links to the membership page. I’m sure this can be fixed by just having the scraper go to the article page and grabbing the url.

  3. Article’s publish dates are still there but likely have moved in the HTML structure from what I could gleam using inspect. Likely a simple fix of just telling the scraper where to look. This is likely the same thing that happened to how it grabs the start of an article’s body.

I tried figuring it out myself to try and get the scraper working again, but I have 0 knowledge of Node.js or scrapers. I understand what might be wrong, I think, but I simply don’t know how to code it. I was hoping someone with better knowledge of this stuff would be willing to rewrite that part of the code. It’d be nice to relaunch the bot with a new account, since it the last remnant of imadeanaccount. Plus, I just like this bot honestly. Happy to help if I can.

Code is here: https://github.com/imadeanaccount1/onionbot/

comments (single view)

apparently the onion is making print magazines again too

View all comments