Temp logging of csvs to files

This commit is contained in:
Adam Goldsmith 2018-06-12 01:42:17 -04:00
parent cbc049ce68
commit a9df94a5ad

View File

@ -95,7 +95,10 @@ def makeDoor(doorName, doorData, members, hashes):
if member is not None:
writer.writerow(member)
print(outString.getvalue())
import datetime as DT
timestamp = DT.datetime.now().strftime("%Y-%m-%d %H:%M:%S")
with open("/tmp/" + doorName + timestamp + ".csv", "w") as f:
f.write(outString.getvalue())
outString.seek(0)
doorHash = md5(bytes(outString.getvalue(), 'utf8')).hexdigest()