-
-
Notifications
You must be signed in to change notification settings - Fork 22
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
bug: RRULE Timezone must be in UTC format - ends in Z #28
Comments
on my limited testing - I think this maybe a potential issue with the python-dateutil module 2.8.1 |
Hi and thanks! I somewhere read that still it might be good to test your
dependencies. Since we created an issue here, we can still write a test
which fails so that other people can download the test suite to their
computer and run it to see if the dependencies are up-to-date.
In a way - I also heard that this was the old open-source way - that
code you include is code you are responsible for.
On the other hand: This module includes dependencies which are installed
with it. Might it be that we should change something about how the
dependencies are specified in the requirements.txt file?
What are your thoughts?
|
not sure what you mean - new to this (as actually just user not developer of someone elses component that called this module!) , but are you referring that the requirements.txt should have a reference to python-dateutil to be at least 2.8.1 to test? I tried to write a test script but can't figure out what I'm supposed to do in the event that another module raises the error other than it marking as an expected failure - but that would be until potentially it gets fixed in which case the test would need to be updated to remove the expected failure? I tried something like this with the associated ics file which tests that it should have 15 not 17 events (the exceptions) which I can test if I manually remove the Z's and will correctly fail and hopefully mark it as skipping if it raises any ValueError? import pytest
@pytest.mark.xfail(raises=ValueError)
def test_expectedamountofevents(calendars):
events = calendars.issue_28_rrule_with_UTC_endinginZ.between((2020, 5, 25),(2020, 9, 5))
assert len(events) == 15 |
@a-nicholls Thanks for providing so much information. I added your file and the test. Let's see how this can be fixed. |
When I update the dateutil module to version 2.2, I get another error.
This error occurs in your test and in the test of Issue 4. |
@a-nicholls I added code and now the test fails in the number of expected events.
What do you think how we should proceed? |
Yeah looks similar to the datetime module, the problem with local time being required to be in UTC and the exceptions are saved in UTC+1 (which I believe is correct) so there should be 17 items not 19. The comparisons in my mind should be all converted to the same time to local time to figure out which exceptions have to be removed |
This fix is released in Version v0.1.17 |
Should we re-open this issue or open a new one since the test is wrong? |
actually the test written did do a test against 15 not 17, so the test file will need to be changed back and it makes sense as problem was mentioned also in issue to reopen this issue if that's ok? |
This refers to #28 (comment) This reverts commit 9264cae.
when the recurrence/id differs in format from the date, this solves some problems refers to #28 (comment)
@a-nicholls Thanks again for reporting... I could fix the tests and opened an issue for the broader problem of matching recurrence-ids. #36 |
Again, let me know if you have input! |
This fix is included in v0.1.18b. |
looks like that did it! with the test program above, should the calling of |
I think, it is not supposed to be ordered. I never wrote tests for that.
The reason: What should it be ordered by? Start, End, Duration, ...
|
ah ok - apparently the module that uses this great library is doing the sort :) no problems :) |
Describe the bug
I've shared a calendar from Office 365 that shares out the ics link (downloaded file below)
but running with test code reports RRULE UNTIL values must be specified in UTC when DTSTART is timezone-aware
From what I've read the UTC time format can include a trailing Z to indicate UTC time?
If I remove the Z from the RRULE UTIL value it shows the dates but with incorrect changes - I'm guessing this is because the date is not in same time zone UTC +1?)
To Reproduce
ICS file
test.ics.txt
Expected behavior
I expect it to not show two of the dates (2020-05-28 and 2020-09-03)
Console output
Version:
Additional context
I'm new to python and pull requests - but happy to have a go at putting in a test
Suggested implementation
python-recurring-ical-events/test/calendars/issue-15-duplicated-events.ics
Line 1 in f4a90b2
python-recurring-ical-events/test/test_issue_15.py
Line 21 in f4a90b2
We're using Polar.sh so you can upvote and help fund this issue. We receive the funding once the issue is completed & confirmed by you. Thank you in advance for helping prioritize & fund our work.
The text was updated successfully, but these errors were encountered: