jtxBoard icon indicating copy to clipboard operation
jtxBoard copied to clipboard

[BUG] Task widget shows wrong due time for tasks in foreign time zone

Open miklcct opened this issue 11 months ago • 11 comments

Describe the bug

The task widget shows a wrong due time for tasks in a foreign time zone.

To Reproduce

  1. Add a task in another time zone.
  2. Add a task widget.

Expected behavior It shows the correct due time, translated to the device time zone.

Screenshots Screenshot_20240317-212911.png

Screenshot_20240317-212844.png

Screenshot_20240317-212838.png

Device and version

  • Device: Motorola moto g84 5G
  • Android version: Android 13
  • jtx Board version: 2.07.01.gplay
  • Downloaded from: Google Play

miklcct avatar Mar 17 '24 21:03 miklcct

Hi @miklcct ! Thank you for your bug report! One more detail: in the settings for "select display of time with timezone", which option did you choose?

patrickunterwegs avatar Mar 20 '24 21:03 patrickunterwegs

Hi @miklcct ! Thank you for your bug report! One more detail: in the settings for "select display of time with timezone", which option did you choose?

I chose both

miklcct avatar Mar 20 '24 21:03 miklcct

Okay, thank you! Would you expect to see also both times in the Widget?

patrickunterwegs avatar Mar 20 '24 21:03 patrickunterwegs

Hi @miklcct ! Thank you for your bug report! One more detail: in the settings for "select display of time with timezone", which option did you choose?

I chose both

Same here. No matter which option is selected, the widget displays due dates in UTC time zone. (Which is, in my case, not the device's time zone).

Regards

duerrhannes avatar Mar 21 '24 08:03 duerrhannes

thanks @miklcct @duerrhannes Indeed the implementation is not correct there. I will provide a fix soon. I will change it in a way, so that the widget shows the same as the app (also with the text).

The one question remains, when you choose to show both times (just because myself I'm also not sure what to do with that case) - would you like to see both dates/times in the local and in the given timezone or just one of them?

patrickunterwegs avatar Mar 22 '24 22:03 patrickunterwegs

Sorry, my question is also kind of obsolete, I will just do the same as in the list view for now (where the local time is shown)

patrickunterwegs avatar Mar 22 '24 22:03 patrickunterwegs

It seems that the time is still wrong with a recurring task at UTC+8, device in UTC+1, version 2.7.2

miklcct avatar Apr 01 '24 10:04 miklcct

Hi @miklcct , thank you for the update. You mean it's still wrong in general or specifically when you have a recurring task?

patrickunterwegs avatar Apr 01 '24 18:04 patrickunterwegs

Hi @miklcct , thank you for the update. You mean it's still wrong in general or specifically when you have a recurring task?

I can't try it out yet as my widget is filled with other tasks.

miklcct avatar Apr 01 '24 18:04 miklcct

Could you attach one of your problematic entries as an exported .ics file? I just tried to reproduce the issue, but for me it is the expected behavior. The widget shows the time in the local timezone (ie. the time in the timezone of the device).

patrickunterwegs avatar Apr 01 '24 18:04 patrickunterwegs

BEGIN:VCALENDAR
VERSION:2.0
PRODID:+//IDN bitfire.at//ical4android
BEGIN:VTODO
DTSTAMP:20240401T212050Z
UID:5d85557c0aca5baa62efce02adae752e
SEQUENCE:0
CREATED:20240331T224517Z
LAST-MODIFIED:20240331T224517Z
SUMMARY:Topup Payme account
DTSTART;TZID=Asia/Hong_Kong:20240331T235959
RECURRENCE-ID;TZID=Asia/Hong_Kong:20240331T235959
PERCENT-COMPLETE:0
PRIORITY:0
DUE;TZID=Asia/Hong_Kong:20240331T235959
END:VTODO
END:VCALENDAR

Screenshot_20240401-222500

miklcct avatar Apr 01 '24 21:04 miklcct