bitfireAT / davx5-ose

DAVx⁵ is an open-source CalDAV/CardDAV suite and sync app for Android. You can also access your online files (WebDAV) with it.
https://www.davx5.com
GNU General Public License v3.0
1.44k stars 74 forks source link

[Synology] Unsupported operand types: string + string in RRule.php #918

Closed devvv4ever closed 1 week ago

devvv4ever commented 1 month ago

There seem to be certain recurring events (RRULEs) where Synology Calendar v2.5 is crashing when it wants to process it.

The error occurs on a REPORT on a resource like http://192.168.10.42:5000/caldav.php/username/home/ and throws an exception.

HTTP REQUEST
Request{method=REPORT, url=http://192.168.10.42:5000/caldav.php/username/home/, headers=[Depth:1, User-Agent:DAVx5/4.4.1.1-gplay (2024/07/12; dav4jvm; okhttp/4.12.0) Android/14, Accept-Language:de-DE, de;q=0.7, *;q=0.5]}
<?xml version='1.0' encoding='UTF-8' ?><CAL:calendar-query xmlns="DAV:" xmlns:CAL="urn:ietf:params:xml:ns:caldav"><prop><getetag /></prop><CAL:filter><CAL:comp-filter name="VCALENDAR"><CAL:comp-filter name="VEVENT"><CAL:time-range start="20240415T071927Z" /></CAL:comp-filter></CAL:comp-filter></CAL:filter></CAL:calendar-query>

HTTP RESPONSE
Response{protocol=http/1.1, code=500, message=Internal Server Error, url=http://192.168.10.42:5000/caldav.php/username/home/}
Exception [0] Unsupported operand types: string + string
At line 138 of /volume1/@appstore/Calendar/davical/inc/RRule.php
================= Stack Trace ===================
/volume1/@appstore/Calendar/davical/htdocs/caldav.php[109] include_once()
/volume1/@appstore/Calendar/davical/inc/caldav-REPORT.php[251] include()
/volume1/@appstore/Calendar/davical/inc/caldav-REPORT-calquery.php[467] expand_event_instances()
/volume1/@appstore/Calendar/davical/inc/RRule.php[1490] Rfc5545Duration->equals()
/volume1/@appstore/Calendar/davical/inc/RRule.php[109] Rfc5545Duration->asSeconds()

This needs to be reported to Synology directly. It should be fixed in the davical/inc/RRule.php around line 138.

rfc2822 commented 1 month ago

Has this already been reported to Synology?

devvv4ever commented 1 month ago

Has this already been reported to Synology?

not yet... do you think this is enough information for Synology so that they can find/fix this?

rfc2822 commented 1 month ago

Yes, it's a specific PHP line so that should be enough to at least have an idea what this is about.

devvv4ever commented 1 month ago

I've reported it now: It is tracked in Synology ticket #3634897 Let's leave it open until we get a response/confirmation by them.

rfc2822 commented 1 month ago

Their response:

For further handling on the issue, our developers would require the following items and confirmation:

  • A debug.dat file with the Calendar package and a remote session to the device?

  • Additionally, can the issue be consistently reproduced on every NAS and DAVx5 for Android device?

  • To better understand the error, could you confirm if it occurs automatically when modifying the RRULE event on the mobile phone? A screen recording would be very helpful.

  • Also, ensure that the NAS has been updated to DSM version 7.2.1-69057 Update 5 and Calendar to version 2.5.1-21153.

Do not hesitate to contact me, if you have any further questions.

Rudi4000 commented 1 month ago

I had this problem, too, and will provide the requested info later today. I synchronised Outlook 2013 calendar with Synology Calendar via CalDavSynchronizer on Windows 10 and Samsung Galaxy A53 and Tab S9FE via DAVx5. The failure was always the same, but the interesting thing was that it happened after the update from Synology Calendar v2.4 to v2.5. After a new set up of the calendar without recurring events the problem was solved, but I couldn't find out with recurring event it caused.

Rudi4000 commented 1 month ago

I am using Synology Calendar v2.5.1-21153 and Synology DSM 7.2.1-69057 Update 5. "To better understand the error, could you confirm if it occurs automatically when modifying the RRULE event on the mobile phone? A screen recording would be very helpful." => The error occurred whenever I synchronised. Since I couldn't find out which reuccing event caused the error, I couldn't change the event. However, I first deleted all recurring birthday events and the error was still there. Second I deleted all recurring events in Outlook and synchronised and the error was still there.

rfc2822 commented 1 week ago

Has this been a problem recently? Can we close the issue? At least it seems so according to Synology Calendar change logs:

grafik

devvv4ever commented 1 week ago

Nothing changed... The issue was auto-closed on Synology ticket system meanwhile since they did not seem to continue to investigate. The "Fixed Issue" is the changelogs is most likely something else.

rfc2822 commented 1 week ago

Well it's not our bug so is there any use in keeping it open here?

devvv4ever commented 6 days ago

The user reported that it was fixed by reinstalling the Calendar package while also exporting and importing the ical data back again.