Merge branch 'master' into master

This commit is contained in:
Stefano 2022-04-05 23:24:41 -07:00 committed by GitHub
commit 4cdfa5d832
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 3 deletions

View file

@ -15,6 +15,7 @@
failcount = 0
successcount = 0
totalcount = 0
jsonfile = open("../web/atlas.json", "r", encoding='utf-8')
existing = json.load(jsonfile)
@ -73,10 +74,11 @@
text = "\n".join(lines)
try:
outfile.write(json.dumps(json.loads(text))+",\n")
successcount += 1
except json.JSONDecodeError:
failfile.write(text+",\n")
failcount += 1
print("written "+submission.id+" submitted "+str(round(time.time()-submission.created_utc))+" seconds ago")
successcount += 1
totalcount += 1
print(f"\n\nSuccess: {successcount}\nFail: {failcount}\nPlease check manual_atlas.txt for failed entries to manually resolve.")
print(f"\n\nSuccess: {successcount}/{totalcount}\nFail: {failcount}/{totalcount}\nPlease check manual_atlas.txt for failed entries to manually resolve.")

View file

@ -9,6 +9,6 @@
if (len(sys.argv) > 1):
path = sys.argv[1]
json.load(open(path))
json.load(open(path, "r", encoding='utf-8'))
print("JSON is valid")