msmazh
msmazh

Reputation: 895

How to get ALL submissions and comments posted by a list of redditors?

I need to get all the submissions and comments posted on Reddit for a list of usernames. I've created a redditor instance in PRAW:

import praw  
reddit = praw.Reddit(client_id='client_id',
                client_secret='client_secret',
                user_agent='Crawling (by /u/username)',
                username='username',
                password='password')
redditor = reddit.redditor('username1')

So I can get new submissions through this line of code:

redditor.submissions.new()

But I'm wondering how can I get ALL submissions and comments for a username?

Upvotes: 0

Views: 795

Answers (1)

A. Pond
A. Pond

Reputation: 370

In order to get more submissions from a user change the limit attribute of the new method. By default I believe the value of limit is 25, but you can raise the limit with this line.

    redditor.submissions.new(limit=1000) #you can use any number in place of 1000

Upvotes: 1

Related Questions