News for hackers. Stuff that matters.
Re:Twint – Twitter scraping tool written in Python by simonw on Monday April 13, 2020 @07:10AM (#22854766)
If people are resorting to scraping then clearly the official API isn't fit for their purposes.

As an example, here are two key features that are missing from the Twitter API at the moment:

- Bookmarks. You can privately bookmark tweets on the Twitter website and apps. There is no way to access the list of tweets you have bookmarked in the API.

- Threads. The concept of threads - where a tweet has replies from the same author get special treatment in terms of display - is key to how Twitter is used today. The official API doesn't support them, in that there is no way to look at a tweet and see that there exists a threaded tweet reply.

There is no good commercial reason for excluding either of these features from the public API, other than that Twitter have made a strategic decision not to invest resources in expanding the API to keep up with new features they are adding to the platform.

Given that, is it any surprise that people are resorting to scraping?

Re:Twint – Twitter scraping tool written in Python by simonw on Monday April 13, 2020 @07:12AM (#22854776)
You say "maybe they have a reason for not providing everything" - I cannot think of a reason not to provide me with API access to my own private bookmarks other than "we decided to invest our engineering resources elsewhere".

Which isn't a bad reason! But it's not a good argument for people not to scrape their own data.

Re:Twint – Twitter scraping tool written in Python by dewey on Monday April 13, 2020 @08:20AM (#22855176)
> But it's not a good argument for people not to scrape their own data.

Why would you want to scrape your own data if you an already request all your data and get a whole archive? https://help.twitter.com/en/managing-your-account/how-to-dow...

Re:Twint – Twitter scraping tool written in Python by simonw on Monday April 13, 2020 @08:27AM (#22855226)
Because then you have to trigger and download a GB+ file every time you want to programmatically access your latest bookmarks.
Re:Twint – Twitter scraping tool written in Python by numpad0 on Monday April 13, 2020 @07:37AM (#22854910)
Everything Twitter used to and not anymore enable third party profit off “their valuable” data. It’s economically/strategically unsustainable or so they think.
Re:Twint – Twitter scraping tool written in Python by fireattack on Monday April 13, 2020 @11:07AM (#22856464)
API can only get first 3200 tweets from a user is also a dealbreaker.
Re:Twint – Twitter scraping tool written in Python by scared2 on Monday April 13, 2020 @07:15AM (#22854795)
Or they don't know how to effectively use the API, maybe.
Re:Twint – Twitter scraping tool written in Python by simonw on Monday April 13, 2020 @07:21AM (#22854837)
I doubt it. People who write scrapers are talented engineers. Talented engineers understand the limitations of scraping compared to using an official API, and know to try to get things done with the official API first.

The Twint README calls out reasons for going beyond the API at the start - things like Twitter's increasingly strict rate limits and the limit of only 3,200 historic tweets for a user account.

Re:Twint – Twitter scraping tool written in Python by paulgb on Monday April 13, 2020 @07:51AM (#22854989)
I've been maintaining a browser extension[1] that has used various versions of the unofficial API over a period of six years -- from literally navigating the site as the user and grabbing HTML, to the various incarnations of JSON and HTML hybrid (SSR) APIs that their web and mobile clients have used internally over that time.

Believe me, I would LOVE if the official API supported threads. I have tried several times to make it work, but the official APIs are stuck in a circa-2012 idea of how Twitter works. Replies just aren't a thing to it.

[1] https://github.com/paulgb/Treeverse

Re:Twint – Twitter scraping tool written in Python by scared2 on Wednesday April 15, 2020 @03:39PM (#22882091)
I don't think this program actually solved the 3,200 limit you mentioned, not sure though.
Re:Twint – Twitter scraping tool written in Python by armitron on Monday April 13, 2020 @08:49AM (#22855367)
People who write robust, performant, maintainable systems that don’t collapse under their own weight are talented engineers.

Most scrapers including this one lack these characteristics.

Re:Twint – Twitter scraping tool written in Python by scared2 on Wednesday April 15, 2020 @03:42PM (#22882124)
I totally agree, writing scrapers doesn't necessarily make one a talented engineer. You may often find it easier to write a scrapers than going through the API documentation or series of authentication procedures.