Now twitterString forces string for the episode and season values, and changed verified print statement to say verified instead of emoji (y)

This commit is contained in:
2017-03-05 16:34:21 +01:00
parent 315a138380
commit 169083960a

View File

@@ -47,8 +47,9 @@ def createPasteee(episode):
return Paste(prettifyEpisode(episode), private=False, desc="My first paste", views=10)
def tweetString(episode):
tweetString = '@KevinMidboe\nAdded episode:\n' + episode['name'] + ' S' + episode['season']\
+ 'E' + episode['episode'] + '\nDetails: '
print(type(episode['episode']), episode)
tweetString = '@KevinMidboe\nAdded episode:\n' + episode['name'] + ' S' + str(episode['season'])\
+ 'E' + str(episode['episode']) + '\nDetails: '
return tweetString
# TODO What if error when tweeting, no id_str
@@ -100,7 +101,7 @@ def verifyByID(id):
def parseReply(tweet):
if b'\xf0\x9f\x91\x8d' in tweet.text.encode('utf-8'):
print('👍')
print('Verified!')
verifyByID(tweet.in_reply_to_status_id_str)
def getReply(tweet):
@@ -131,4 +132,4 @@ def tweetNewEpisodes():
if __name__ == '__main__':
tweetNewEpisodes()