Android - getting home timeline (sometimes) gives spam tweets

android
twitter4j

#1

I should mention that I am using twitter4j library to fetch home timeline of an Android user. Most of the times, the tweet Ids I get are genuine tweets and it works well. But many times, I get a few spam tweets (in other languages or porn or adult images etc). I have no idea where these tweets are coming from. Any lead will be appreciated to get me a better hold on the problem.


#2

(since you are not using Fabric, I’ll move this over to the REST API section).

Does this consistently occur for a specific user ID?

Is there any reason why those spammy Tweets could be appearing in the timeline? i.e. are they being retweeted by someone the user follows, does the user follow the account(s) from which the spammy Tweets are generated?

If you are using the timelines methods in twitter4j then they should just be hitting the timeline methods on the public API, and I’m not aware of issues with those at the moment.


#3

Thank you for the response and I apologize for wrong category selection.
To answer your questions, No, this does not happen with specific IDs. It is happening with almost all users.
They are surely not retweets and I believe them not to be random tweets also, because as I mentioned, they are mostly porn images or some weird symbols or usually a foreign language (I guess).
And yes, I am calling getHomeTimeline() from twitter4j. And they are supposed to just hit Twitter’s REST APIs. So it is hard to get a track from where these tweets are coming.


#4

Are you able to provide example user IDs that you’ve tried this with, and results?


#5

I apologize. We had a tight deadline and we didn’t need the tweets of different languages so we implemented a workaround and limited the tweets to specific languages, English and Hindi. It’s been about 15 days and we haven’t got any spam or explicit images. Just a workaround for whoever faces the same problem.