diff --git a/docker-compose.yml b/docker-compose.yml index ccfcbc0..d078fc9 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -3,5 +3,7 @@ version: "3.0" services: botyam: build: . + environment: + - PYTHONUNBUFFERED=1 env_file: - /etc/environment \ No newline at end of file diff --git a/src/BotYamPoster.py b/src/BotYamPoster.py index 5980d44..cd5d8f7 100644 --- a/src/BotYamPoster.py +++ b/src/BotYamPoster.py @@ -11,7 +11,7 @@ def post_reply(conn, victim_bank, tweet, words, reply_text_bank, postcounter): if any(word in tweet.data['text'] for word in words): reply_text = reply_text_bank[random.randint(0, (len(reply_text_bank)-1))] # Post reply - if tweet.data['author_id'] in victim_bank.author_id: + if tweet.data['author_id'] in victim_bank['author_id']: reply_text = victim_bank['reply'][random.randint(0,2)] + "\n" + reply_text res = conn.api.create_tweet( text=reply_text,