forked from Decentrala/website
Support for commas
This commit is contained in:
parent
25662d7bda
commit
f9713e7ee0
3
prep.py
3
prep.py
@ -9,9 +9,10 @@ DAYS_EN = ["MON ", "TUE", "WED", "THU", "FRI", "SAT", "SUN"]
|
||||
def load_events(csv_path:str) -> list[dict]:
|
||||
events = []
|
||||
with open(csv_path) as csv_file:
|
||||
csv_reader = csv.reader(csv_file)
|
||||
csv_reader = csv.reader(csv_file, skipinitialspace=True)
|
||||
next(csv_reader, None)
|
||||
for event in csv_reader:
|
||||
print(event)
|
||||
event_date = event[0]
|
||||
event_date_parsed = datetime.strptime(event_date, "%d-%m-%Y").date()
|
||||
event_time = event[1]
|
||||
|
Loading…
Reference in New Issue
Block a user