-
-
Notifications
You must be signed in to change notification settings - Fork 519
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
Should use DTSTART as first occurrence #84
Comments
Plus 1 on this. RRule isn't honoring the startdate/duration on the demo app at all |
Agreed, this threw me off when dealing with Google RFC 2445 java lib. |
👍 This is how the standard (and compliant systems like Google Calendar, Apple (Mac OS/iOS/iCloud) Calendar works. |
@jkbrzt, Right now, rrule.js is tied to python dateutil's functionality
This would seem like a large departure from dateutil, which would seem to make sense in this case. It would involve changing almost all of the test cases. Thoughts? Would you support the change? |
@hwangmoretime I've merged your changes to the README documenting where rrule.js differs from the RFC, thanks for that. Yeah, It would make a lot of sense to make |
I believe this still has a bug. This works for rruleSet rruleSet.valueOf() rruleSet.all()[0] rruleSet.between(startDatetime, endDatetime) note that for the call to method |
here's a bit more context. As far as I can tell, the rruleset is doing precisely the opposite of what I expected. It produces a list of dates, where the zeroth element is the start of the original desired event. But it's the current time the gets expanded into a series of dates. I expected to get a list of dates on Jan 21st, but rruleset "recurred" using the current time (march 22). I've pulled the repo and am trying to narrow this down with some tests but any advice is appreciated. |
I had a similar problem with dtstart. See https://stackoverflow.com/questions/54517101/rrule-not-setting-correct-time-if-dtstart-is-set |
I agree, by default the I made a codepen demonstrating the subtleties of the current behavior: https://codepen.io/arshaw/pen/qwEQNO?editors=0010 |
Agreed. Getting up to speed on rrule now. It's a great timesaver (thank you!), but this inclusive date issue an odd nuance that requires some custom logic to address. Would love to see this updated. Understood that current behavior consistent with python-dateutil, but I think priority should be on behavior consistent with the RFC standard, rather than perpetuating an odd deviation. Also, per comment below:
As best I can tell, this significantly understates the complexity of the workaround needed for many use cases. For example, assume you have the following rule parameters:
This should translate to "every 2 weeks on Monday for 10 times", with a start date of Sunday, November 1st, 2020. Now, the very first calendar Monday after the start date is November 2nd... so, with an interval of 2, we would expect generated event dates to be Nov 2, Nov 16, Nov 30, etc. However, the |
I personally like the way this package deals with it but the difference in behaviors is confusing when considering the way the actual protocol and calendars deal with DTSTART. Because when I generate an ical using the rrule gnerated here the calendar produces the extra first occurrence. My two cents is that the package should include the DTSTART by default and pass a bool in the Side note: The package is looking for active maintainers if anyone is interested #450 |
According to the iCalendar specification:
And it includes an example of this:
rrule.js doesn't include September 2nd as an occurrence. In rrule.js the first occurrence is September 3rd.
The text was updated successfully, but these errors were encountered: