我正在尝试学习如何在Python中创建Reddit机器人,但是得到以下错误消息。。。在
C:\Users\Warbz\Desktop>python redditbot.py
Logging in...
Grabbing subreddit...
Grabbing comments...
Traceback (most recent call last):
File "redditbot.py", line 30, in <module>
run_bot()
File "redditbot.py", line 19, in run_bot
for comment in subredditComments:
TypeError: 'CommentHelper' object is not iterable
我的代码是。。。在
^{pr2}$我试过查看prawapi,但我不确定到底出了什么问题,有什么帮助吗?在
comments
提供CommentHelper的一个实例,需要使用括号实例化该实例来调用它。在https://praw.readthedocs.io/en/latest/code_overview/models/subreddit.html#praw.models.Subreddit.comments
相关问题 更多 >
编程相关推荐