Skip to content
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

Fix Alarm related to DTSTART of VTODO #616

Merged
merged 1 commit into from
Aug 28, 2024

Conversation

tpayen
Copy link
Contributor

@tpayen tpayen commented Apr 7, 2023

Following RFC 5545 (https://www.rfc-editor.org/rfc/rfc5545#page-74) the start of a VTODO is DTSTART not DUE
Fixing the tests in consequence

@jarikmarwede
Copy link
Contributor

I have just noticed the same problem to be the cause of an error in my application and have come to the same conclusion for fixing it.
Is there a reason this isn't merged yet, or can I somehow help in getting this merged? @evert
Sorry, if the mention isn't correct. You are the one marked as the author in the PHPDoc comment for the VAlarm class.

@jarikmarwede
Copy link
Contributor

It also seems to me like this is a duplicate of #370, although that PR isn't merged either because it was missing tests in 2017 and now has merge conflicts.

Copy link

codecov bot commented Aug 28, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.78%. Comparing base (e1cc246) to head (d734e21).
Report is 3 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #616      +/-   ##
============================================
- Coverage     98.78%   98.78%   -0.01%     
+ Complexity     1875     1874       -1     
============================================
  Files            71       71              
  Lines          5273     5270       -3     
============================================
- Hits           5209     5206       -3     
  Misses           64       64              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@phil-davis

This comment was marked as resolved.

Following RFC 5545 the start of a VTODO is DTSTART not DUE
Fixing the tests in consequence
@phil-davis
Copy link
Contributor

Note for myself and other readers.
I wondered about the code in the "else" that deals with "not START". That has a similar if-else that chooses property "DUE" or "DTEND". The RFC (see link above) has this text in it:

"In an alarm in a "VTODO" calendar component set
to trigger on the "END" of the to-do, either the "DUE" property
MUST be present, or the "DTSTART" and "DURATION" properties MUST
both be present."

So the RFC does expect that there can/must be a "DUE" property. So that code looks reasonable.

Maybe there should be other code somewhere that handles a "DTSTART" and "DURATION" combination. I haven't looked hard for that. And it is out-of-scope for this fix anyway.

@phil-davis phil-davis merged commit 3e1e0d3 into sabre-io:master Aug 28, 2024
8 checks passed
@phil-davis phil-davis mentioned this pull request Aug 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants