-
-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exception is thrown: can't compare offset-naive and offset-aware datetimes #69
Comments
@thegrandpoobah What happens if you use Changing your example code to from datetime import datetime
evs = events(url=url, start=datetime(2020, 9, 1), end=datetime(2020, 9, 30))
for event in evs:
print(event) If that doesn't work do you think you could provide a full runnable example? |
Hello, that doesn't work either. I will craft a working error case and create a repo for you. |
Here is the reproducible test case: https://github.com/thegrandpoobah/icalevents69 |
Using Python 3.7.4 with icalevents 0.1.25 and icalendar 4.0.6 |
@Hultner I made a PR for this issue, it's a quick fix so I'm open to feedback on the solution. PTAL, thank you! |
This also occurs with a recurring, all-day events. Things are coerced to naive timezones here https://github.com/irgangla/icalevents/blob/master/icalevents/icalparser.py#L304-L315 , but the |
I have a similar issue when try this code against the attached google calendar generated ics file:
|
I don't think the PR linked here is a complete fix unfortunately. I'm still running into the exception even after installing the latest commit via pip. The test file that @daleiliu linked above reproduces it still, doing nothing more than:
|
Still an issue, just installed via pip today. Using datetime objects as suggested. |
Is there any workaround for this? Can I modify the ics file to make it work for recurring all-day events? |
I've also just run into this bug and am trying to suss out how to work around it. |
Just had this problem (with a vCalendar generated by korganizer with an event from 2003) |
Hello, is there an update on this issue please? It's still there. thanks! |
closed by: #140 thank you very much for the documentation and the example @thegrandpoobah |
Hello, I am trying to use the icalevents library to parse a iCal feed generated by Bamboo HR for our company time offs.
Here is the code that I am using:
This throws the following error:
Not sure if I'm doing something wrong, if the iCal is malformed for whatever reason, or if there is a bug in the library, but I've attached the calendar in question to start:
holidays.ics.txt
Any thoughts on this?
The text was updated successfully, but these errors were encountered: