-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
39 lines (22 loc) · 819 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Main Scrapper File to RUN
# Imports
# Local imports
from redscrap.scrapper import RedScrap
from redscrap.utils import get_command_line_args
if __name__ == "__main__":
# Get command line arguments
# start_date, end_date, search_terms, subreddits = get_command_line_args()
# Setting parameters
start_date = "2020-11-01"
end_date = "2020-11-02"
# Search terms
search_terms = [ "COVID|corona" ]
# Subreddits to look in.... (default=ALL)
subreddits = []
# Creating a RedScrapper Object
scrapper = RedScrap(start_date=start_date,
end_date=end_date,
search_terms=search_terms
)
# Get Reddit Submissions
scrapper.retrieve_submissions(retrieve_comments=False)