mirror of
https://github.com/placeAtlas/atlas.git
synced 2024-11-15 14:33:36 +01:00
fix and update crawler
This commit is contained in:
parent
1f2d35b802
commit
6206596da1
2 changed files with 3 additions and 2 deletions
|
@ -24,7 +24,7 @@
|
|||
existing_ids.append(item['id'])
|
||||
|
||||
|
||||
for submission in reddit.subreddit('placeAtlas2').new(limit=500):
|
||||
for submission in reddit.subreddit('placeAtlas2').new(limit=1000):
|
||||
"""
|
||||
Auth setup
|
||||
1. Head to https://www.reddit.com/prefs/apps
|
||||
|
@ -47,6 +47,7 @@
|
|||
"""
|
||||
#print(dir(submission))
|
||||
if (submission.id in existing_ids):
|
||||
print("Found first duplicate!")
|
||||
break
|
||||
if(submission.link_flair_text == "New Entry"):
|
||||
text = submission.selftext
|
||||
|
|
|
@ -79,7 +79,7 @@ init();
|
|||
|
||||
async function init(){
|
||||
|
||||
let resp = await fetch("./atlas.json");
|
||||
let resp = await fetch("/atlas.json");
|
||||
atlas = await resp.json();
|
||||
atlas.sort(function (a, b) {
|
||||
if (a.center[1] < b.center[1]) {
|
||||
|
|
Loading…
Reference in a new issue