Tweets my bot replies to don't appear in details expand



My bot replies to tweets but the replied to tweet doesn’t appear on details expand. I’m using the ‘twitter’ ruby gem and this code:, count: 10).each do |t|
  quote = quotes.sample
  word = trollWords.sample
  replystring = "@" + t.user.screen_name + " " + quote
  puts "Found possible troll suspect: " + t.user.screen_name + "\nTweeting: " + t.text + "\nReplied with: " + replystring + "\n"
  client.update(replystring, in_reply_to_status_id: t)

If people can’t see what the bot is replying to, but kinda ruins a lot of the concept so I was wondering if there’s a way to make the reply appear properly, as a reply tweet would normally appear when using the website itself rather than the API?


Can you verify that it is a proper reply? (It should have the “In reply to…” text in the web view)
If it is, it’s possible that this is some filtering done by Twitter and you can’t do anything about it.
If it is not, it might be that you are not passing the right thing for in_reply_to_status_id. From your code it looks like you pass a tweet object instead of the actual id, but I am not familiar with that library so it might be correct in that case. I was expecting that the ID is passed there, though.


Hhhm. Passing in the id fixed it for two tweets (‘in reply’ started appearing). Then the bot reverted to previous behaviour (no ‘in reply’) then the tweets stopped appearing completely. If it’s Twitter filtering it seems odd, especially since everything seems to be within terms and conditions and the bot is only quoting great literature fairly infrequently (once per 25 minutes atm) at what it identifies as potential trolls according to keyword, which seems both potentially interesting and mostly harmless.

I know Twitter have got quite political recently but I must admit if this stuff is being censored I’m a little baffled as to why.

If it’s just a glitch I can always go the long way around and use automated browser behaviour to achieve the same effect but I’d rather do things properly through the API if possible. Not least because using Selenium or zombie.js it’s much harder to know if Twitter are OK with stuff you’re doing and I don’t want to find myself IP range banned just because I’m using something unofficial.


If that fixed it for two tweet, it should work for all Tweet unless there is some bug with your code, I think. Twitter might filter the reply when you use the thread view for the tweet you replied to, but for the specific reply you should always see the “in reply to”. Note that you might need to use the id_str instead of the ID to make sure it will use the correct id, with some programming languages, due to problems handling 64bit integers in JSON.