[DateTime] Appsettings date picker on GCM iOS resets the date upon reconfiguration

Environment:
  • iOS Garmin Connect Mobile app
  • All Garmin Connect IQ compatible devices
  • Bug exists since CIQ SDK 1.2.0 release

Detailed Description:

The date picker in the iOS Garmin Connect Mobile (GCM) app does not retain a previously configured date.
When entering app settings, any previously configured date is reset, and a user has to ensure the date is set before saving, even when just configuring any other non-date related settings.
Failing to set the date again will cause the date setting on the device to be overridden with the current date when saving the app settings.

Steps to reproduce:

Approach 1:
  • Create a watch face with a date property to be configured with app settings
  • Make sure to print the value of this property on the device's display
  • Upload the watch face to the store
  • Install the watch face to any compatible Garmin watch
  • Use GCM app on iOS to configure the settings for the watch face.
  • Pick a date and save the settings.
  • Note the date on the screen
  • Open app settings again in GCM iOS
  • Note that the date picker is empty and does not show the previously configured date
  • Without picking a date, save the settings
  • Note how the date changes to the current date on the device's display

Approach 2:
  • Install my watch face Countdown! to any compatible Garmin watch
  • Use GCM app on iOS to configure the event settings for Countdown!.
  • Set event name and pick a date for the event and save the settings.
  • Note the date on the bottom half of the screen
  • Open app settings again in GCM iOS
  • Note that the event date picker is empty and does not show the previously configured date
  • Without picking a date, save the settings
  • Note how the date changes to the current date on the device's display

Code sample:

<strings>
<string id="MyDateTitle">Pick a date</string>
</strings>
<properties>
<property id="MyDate" type="number"></property>
</properties>
<settings>
<setting propertyKey="@Properties.MyDate" title="@Strings.MyDateTitle">
<settingConfig type="date" />
</setting>
</settings>
  • Thanks Hermo! I've forwarded this to the GCM team for further investigation. As I've discussed with you offline, we've had this reported before (by you), and though it was resolved by the GCM team, the resolution reason isn't clear to me. There's still a bug here as far as I'm concerned, so I want to push on this to see if we can get a fix in place.
  • This bug was reported over 3 years ago, and it's still not resolved? I recently launched the Merlin watch face in the Connect IQ store and quickly discovered this bug. It's important to be able to maintain the same date in the settings for this app. The automatic date reset is annoying. Please fix. Thank you

  • This was originally one of the old bug reports, and as Hermo noted, started when app settings was introduced in early 2016 (the 1.2.0 SDK).

    While it never got fixed in GCM, if I recall, it does work with the Connect IQ phone app.  I'd instruct users to use that instead of GCM.  

  • , I just tried the Connect IQ app for iOS, and it does not work there, either. Same observations. I have not tried GCM or Connect IQ for Android.

    My workaround will be to create three separate settings for month, day, and year, and use that instead of the date picker entry. There are pros and cons to this, one of the cons being that I will not be able to use the calendar view of the date picker. The calendar view is useful for seeing days of the week. It is unfortunate that the date picker feature is an option but it does not work properly on all platforms.

  • Yes, that's what others have done.  And like I said, the bug has been around for years.

  • I see that the Gregorian.moment function does not automatically correct for when the day value is not valid for the month, e.g., month=2, day=30, and I need to put my own correction for this in my code. This is inconvenient when using this function in the context of a user setting. It would be great if the settings were dynamic, i.e., the days setting would be grayed out until the user selects a month and year, and then options for days are given based on which month and year are chosen (including leap years). I don't suppose there is a way to do this in the settings xml?

  • Nope.  Settings are static.  Actually define when you build the .iq file.

  • LOL. A bug with long history

  • Sir, is it really hard to resolve ? Why would this bug still exist nowadays? LOL