False success on favourite endpoint

favorites
api

#1

I am seeing a strange bug when favoriting certain tweets on the favorites/create endpoint (https://dev.twitter.com/rest/reference/post/favorites/create). Sometimes, the favoriting appears successful but no favorite is ever added to the status.

I am receiving a response from the endpoint with favorited: true and favorite_count: 0.

I see on the docs that “this process invoked by this method is asynchronous”, but it doesn’t matter how long I wait, the favorite is never added. One time when investigating what had happened, I visited the tweet natively and saw this weird state of being liked with 0 count (this is not liking my own status). Eventually the like disappeared.

This does not happen with all tweets and seems to only happen with fairly old tweets (more than a few weeks). I have noticed that if I visit the status natively first then the bug will never happen. Likewise, once I have interacted once with the status through the API the bug doesn’t reoccur. This means if I “retry” the favoriting it always works.


#2

Hi,

I’m trying to reproduce this issue. Is there a tweet that you can reproduce this issue consistently?

Thanks.

Yubin


#3

Hi,

Unfortunately, I cannot reproduce it multiple times on a specific tweet. It only happens once and after having interacted with the tweet it doesn’t reoccur for that particular tweet.

I have now seen this happening on tweets of all kinds of ages, however the age of the tweet does seem to correlate with how likely this is to happen.

Thanks,
Tom


#4

We just need to reproduce this once. Once you favorite a tweet using the API and don’t see the “like” added, please stop interacting with the tweet so that I can verify if it’s data issue in the backend. Would you be able to provide me a tweet id in that case? Thanks.