Jan-25-2019, 04:18 AM
I used 28 01 19 in the events.txt, and put in a print(events) line the out put is: [[datetime.date(2019, 1, 28)]].
A list of a list datetime.date object. Then changed the end of your script
A list of a list datetime.date object. Then changed the end of your script
events = get_events() today = date.today() print(events[0][0]) print(today.isoformat()) myEvents= events[0][0].timetuple() print(myEvents[0]) vertical_space = 100 days_until = days_between_dates(events[0][0], today) days_until = days_between_dates(events[0][0], today) display = 'it is %s days until %s' % (days_until, myEvents[0]) c.create_text(100, vertical_space, anchor='w', fill='lightblue', font='Arial 28 bold', text=display) vertical_space = vertical_space + 30