Merge lp:~renatofilho/qtorganizer5-eds/fix-1445577 into lp:qtorganizer5-eds
| Status: | Merged |
|---|---|
| Approved by: | Charles Kerr on 2015-10-29 |
| Approved revision: | 93 |
| Merged at revision: | 87 |
| Proposed branch: | lp:~renatofilho/qtorganizer5-eds/fix-1445577 |
| Merge into: | lp:qtorganizer5-eds |
| Prerequisite: | lp:~renatofilho/qtorganizer5-eds/fix-1437305 |
| Diff against target: |
104 lines (+57/-7) 3 files modified
debian/rules (+3/-0) organizer/qorganizer-eds-engine.cpp (+16/-7) tests/unittest/event-test.cpp (+38/-0) |
| To merge this branch: | bzr merge lp:~renatofilho/qtorganizer5-eds/fix-1445577 |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Charles Kerr (community) | Approve on 2015-10-29 | ||
| PS Jenkins bot | continuous-integration | Approve on 2015-10-29 | |
| Alan Pope πΊπ§π± π¦ | 2015-10-02 | Pending | |
| Renato Araujo Oliveira Filho | Pending | ||
|
Review via email:
|
|||
This proposal supersedes a proposal from 2015-08-27.
Commit Message
Correct save events with UTC format.
| Gary.Wang (gary-wzl77) wrote : | # |
Actually, there is no such a timezone settings in app. App just follows system timezone.
My Time & Date in system settings
Time zone:
Asia/Shangehai UTC+8
----Create an event (display correctly in weeklyview)
qml: event.name: Ttttt
qml: event.startDate
qml: event.endDateTime: Fri Jul 24 08:00:00 2015 GMT+0800
----Edit an event with only name changed (wrong display and event backs x hours)
qml: event.name: Ttttt-edit
qml: event.startDate
qml: event.endDateTime: Fri Jul 24 08:00:00 2015 GMT+0800
| Gary.Wang (gary-wzl77) wrote : | # |
I check this issue today and find sth as following:
when user modify a event with start or end date time changed, issue wont' occur.
when user modify a event without start datetime and end date time changed, issue occurs.
Reason for this is if start and end date time are not changed when modification, the timeSpec is for these two datetime is Qt::TimeZone instead of Qt::UTC when parsing them, then
tz.id().constData() == "able/localtime" which cause timezone == null and empty for tzId after icaltimezone_
so finally event backs x(timezone) hours after e_cal_client_
As I mentioned above, we follow system timezone and have no way to set timezone in qml.
The easy fix is if start & end datetime are not floating time, then we need to convert Local timezone to UTC time zone.
Please review latest MP.
Thanks
Could you resubmit this MR adding "https:/
| Gary.Wang (gary-wzl77) wrote : | # |
OK, I will delete this one later on and create another MP for review since I can't resubmit merge proposal in same branch.
Thanks.
Could you write a small qml code, that reproduce the error?
We can not save all events with 'UTC' timezone it will cause the alarms to fail, we need to have a way to save events without a specific TZ to floating times.
If js does not support datetime with 'Qt::TimeZone' format we should fix the QML bindings to return it in UTC format. (this need to be done in QtOrganizer)
As workaround we can update the start/stop field before save the event (in calendar app) even if the user does not change it.
But first I need to see the small qml app to make sure that we do not have any other solution.
| Gary.Wang (gary-wzl77) wrote : | # |
This issue can be reproduce easily. Just make sure you have non UTC+0 time
zone on your device. e.g. for me UTC+8
Please find simple qml app here
https:/
Regarding workaround, I've tried add one milliseconds for start/end
datetime before when editing an event, it *works*. But strictly speaking, I
think it's just a workaround not a proper fix.
I have no idea beside eds, if there's another plugins for QtOrganizer(what
kind of plugin use by Jolla)? if it works fine with another plugin, I am
afraid issue lies in eds.
Also applying 'UTC' timezone for all events cause alarm(floating time) to
fail, no idea if there is a way to check if edit item type or sth.
Please try the qml code at first to have a check if it can be reproduced on
your device, Thanks.
It seems we can't check current event type is alarms or
On Tue, Sep 8, 2015 at 9:39 PM, Renato Araujo Oliveira Filho <
<email address hidden>> wrote:
> Could you write a small qml code, that reproduce the error?
>
>
> We can not save all events with 'UTC' timezone it will cause the alarms to
> fail, we need to have a way to save events without a specific TZ to
> floating times.
>
> If js does not support datetime with 'Qt::TimeZone' format we should fix
> the QML bindings to return it in UTC format. (this need to be done in
> QtOrganizer)
>
> As workaround we can update the start/stop field before save the event (in
> calendar app) even if the user does not change it.
>
> But first I need to see the small qml app to make sure that we do not have
> any other solution.
>
> --
>
> https:/
> You are the owner of lp:~gary-wzl77/qtorganizer5-eds/fix_1445577.
>
--
Br
Gary.Wzl
I am trying to reproduce the bug with the example create by Gary. But the log is showing the correct results.
qml: -------------Create event
qml: Birthdays_145 ---- false
qml: Personal ---- false
qml: renatoteste2gma
qml: HolidaysinBrazi
qml: Personal ---- false
qml: Personal ---- true
qml: Birthdays & Anniversaries ---- true
qml: event Name:Test_
qml: startDate: sex out 2 11:58:43 2015 GMT-0300
qml: endDate: sex out 2 12:58:43 2015 GMT-0300
qml: -------------Create event done
qml: -------
qml: editEvent: QDeclarativeOrg
qml: event Name:Test_
qml: startDate: sex out 2 11:58:43 2015 GMT-0300
qml: endDate: sex out 2 12:58:43 2015 GMT-0300
qml: -------
qml:
-------------Edit event
qml: event Name:edit_
qml: startDate: sex out 2 11:58:43 2015 GMT-0300
qml: endDate: sex out 2 12:58:43 2015 GMT-0300
qml: -------------Edit event done
qml: -------
qml: editEvent: QDeclarativeOrg
qml: event Name:edit_
qml: startDate: sex out 2 11:58:43 2015 GMT-0300
qml: endDate: sex out 2 12:58:43 2015 GMT-0300
qml: -------
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:88
http://
Executed test runs:
FAILURE: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
| Gary.Wang (gary-wzl77) wrote : | # |
I have a quick testing on your latest MR.
I see you have a UTC checker when saving an event.
It fixes this problem.
Thanks.
PS: I see you can't reproduce this bug on your side from the comment.I think it's because you have UTC+0 timezone for date/time in your system-setting, If you set non-UTC timezone, it can be reproduced 100%.
- 89. By Renato Araujo Oliveira Filho on 2015-10-28
-
Trunk merged.
- 90. By Renato Araujo Oliveira Filho on 2015-10-28
-
Updated changelog.
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:89
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
deb: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:90
http://
Executed test runs:
FAILURE: http://
SUCCESS: http://
deb: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
- 91. By Renato Araujo Oliveira Filho on 2015-10-28
-
Run tests sequential.
| PS Jenkins bot (ps-jenkins) wrote : | # |
PASSED: Continuous integration, rev:91
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
- 92. By Renato Araujo Oliveira Filho on 2015-10-29
-
Create unit test for events saved on UTC timezone.
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:92
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
- 93. By Renato Araujo Oliveira Filho on 2015-10-29
-
Trunk merged.
| PS Jenkins bot (ps-jenkins) wrote : | # |
PASSED: Continuous integration, rev:93
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://

Reading the bug report I would say that the event is losing the timezone when edited. Is the app setting the correct timezone? If the app does not set the timezone the event will be handled as a Floating event.