From 30428733844b14fcd60a7fd48c2df4bd2f21b1fc Mon Sep 17 00:00:00 2001 From: Matt Huntington Date: Fri, 30 Dec 2022 23:01:33 -0500 Subject: [PATCH] reply to comments not made by bot --- app.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/app.py b/app.py index d2956e5..16c6de7 100644 --- a/app.py +++ b/app.py @@ -1,10 +1,8 @@ import praw reddit = praw.Reddit('bot1') -subreddit = reddit.subreddit('learnpython') +subreddit = reddit.subreddit('mahuntingtontest') -for submission in subreddit.hot(limit=5): - print("Title: ", submission.title) - print("Text: ", submission.selftext) - print("Score: ", submission.score) - print("---------------------------------\n") +for comment in subreddit.stream.comments(): + if comment.author != 'jazzbot2pointw000': + comment.reply('yeah man')