6.0.0-beta1
7/12/25

[#12244] edit event in CalDAV calendar does not work
Summary edit event in CalDAV calendar does not work
Queue Kronolith
Queue Version 4.1.0beta1
Type Bug
State Resolved
Priority 2. Medium
Owners jan (at) horde (dot) org
Requester lst_hoe02 (at) kwsoft (dot) de
Created 05/10/2013 (4446 days ago)
Due
Updated 05/24/2013 (4432 days ago)
Assigned 05/22/2013 (4434 days ago)
Resolved 05/24/2013 (4432 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
05/24/2013 03:13:42 PM Jan Schneider Assigned to Jan Schneider
State ⇒ Resolved
 
05/24/2013 03:03:00 PM Git Commit Comment #8 Reply to this comment
Changes have been made in Git (master):

commit 2d71e345f61047f3c1ecd1e9ea1fee6f3df82479
Author: Jan Schneider <jan@horde.org>
Date:   Fri May 24 17:02:35 2013 +0200

     [jan] Fix editing of events per CalDAV if client sends 
LAST-MODIFIED attribute (Bug #12244).

  kronolith/docs/CHANGES        |    2 ++
  kronolith/lib/Application.php |    2 +-
  kronolith/package.xml         |    4 ++--
  3 files changed, 5 insertions(+), 3 deletions(-)

http://git.horde.org/horde-git/-/commit/2d71e345f61047f3c1ecd1e9ea1fee6f3df82479
05/24/2013 11:10:45 AM lst_hoe02 (at) kwsoft (dot) de Comment #7 Reply to this comment

[Show Quoted Text - 19 lines]
I can also confirm that the workaround fixes the update-event problem, 
but it looks like Lightning/CalDAV has some other flaws. The updated 
event is shown in Kronolith fine, but Thunderbird need a restart to 
actually show the changes done :-(


05/24/2013 07:08:20 AM skhorde (at) smail (dot) inf (dot) fh-bonn-rhein-sieg (dot) de Comment #6 Reply to this comment
Cannot reproduce. Is this with all events? Only certain? Only old, 
only new events?
This code is hit, when one modifies an event.

The problem is actually, that $content->getAttribute('LAST-MODIFIED') 
returns an integer (seconds since epoch), hence, 
$content->getAttribute('LAST-MODIFIED')->before($modified) fires that 
PHP error.

$modified is a string in ISO-format.

My workaround is to cast the integer into ISO-format for comparison, 
if getAttribute('LAST-MODIFIED') returns an integer only.

I posted my upgrade path on 15 May 2013 15:57:52 to the list with 
subject "CalDAV change event fails with PHP error", maybe something 
got screwed up then.
05/23/2013 01:34:22 PM lst_hoe02 (at) kwsoft (dot) de Comment #5 Reply to this comment
Cannot reproduce. Is this with all events? Only certain? Only old, 
only new events?
For me the problem exists with all events created with Tunderbird and 
with Kronolith. It is simply not possible to alter an existing event 
with Tunderbird/Lightning in the CalDAV calendar. Creating/Deleting 
works fine.


05/22/2013 02:49:44 PM Jan Schneider Comment #4
State ⇒ Feedback
Reply to this comment
Cannot reproduce. Is this with all events? Only certain? Only old, 
only new events?
05/17/2013 02:21:49 PM nimm (at) technikum-wien (dot) at Comment #3 Reply to this comment

[Show Quoted Text - 24 lines]
Hi!

I have the same problem when modifying entries with CalDAV Sync App on 
Android 4.1.2 and the workaround is successful.
05/16/2013 11:55:29 AM skhorde (at) smail (dot) inf (dot) fh-bonn-rhein-sieg (dot) de Comment #2 Reply to this comment
Editing a event created with Thunderbird/Lightning (latest on 
Windows) in a Kronolith calender subscribed with CalDAV result in 
"MODIFICATION_FAILED" error.  The server log shows the following:

2013-05-10 10:12:38: (mod_fastcgi.c.2701) FastCGI-stderr: PHP 
message: PHP Fatal error:  Call to a member function before() on a 
non-object in /var/www/horde/kronolith/lib/Application.php on line 822
I use this workaround:

                 try {
                    if(!empty($modified)) {
                        $new_data_time = $content->getAttribute('LAST-MODIFIED');
                        if(!empty($new_data_time)) {
                            //Horde::logMessage('SKA: last-modified: '.$new_data_time. " 
".date("Y-m-d H:i:s", $new_data_time), 'NOTICE');
                            //Horde::logMessage('SKA: modified: '.$modified, 'NOTICE');
                            if(is_object($new_data_time) && $new_data_time->before($modified)
                             || !is_object($new_data_time) && date("Y-m-d H:i:s", 
$new_data_time) < $modified) {
                                /* LAST-MODIFIED timestamp of existing entry is newer:
                                 * don't replace it. */
                                //Horde::logMessage('SKA: modified entry is newer skip update', 'NOTICE');
                                continue;
                            }
                        }
                    }
                 } catch (Horde_Icalendar_Exception $e) {
                 }

05/10/2013 12:13:59 PM lst_hoe02 (at) kwsoft (dot) de Comment #1
Priority ⇒ 2. Medium
State ⇒ Unconfirmed
Patch ⇒ No
Milestone ⇒
Queue ⇒ Kronolith
Summary ⇒ edit event in CalDAV calendar does not work
Type ⇒ Bug
Reply to this comment
Editing a event created with Thunderbird/Lightning (latest on Windows) 
in a Kronolith calender subscribed with CalDAV result in 
"MODIFICATION_FAILED" error.  The server log shows the following:

2013-05-10 10:12:38: (mod_fastcgi.c.2701) FastCGI-stderr: PHP message: 
PHP Fatal error:  Call to a member function before() on a non-object 
in /var/www/horde/kronolith/lib/Application.php on line 822


Saved Queries