Acknowledged

SDK bug in loading properties

Hello,

I have a boolean-property which stopped working, i.e. its value upon invoking

Toybox.Application.Properties.getValue("somePropertyKey")

is 'true' regardless of whether it is set to true/false in properties.xml;

Since it used to work I have changed SDK and found out it worked properly with older SDKs,
i.e. leaving code+properties intact (w/ the prop set to 'false'),
and only changing the SDK being used to compile/run, then compiling+running yield the following results:

  • connectiq-sdk-mac-4.1.1-2022-03-14-18db583bc: Properties.getValue return false, i.e. as expected
  • connectiq-sdk-mac-4.1.2-2022-04-07-15e8df3ed: Properties.getValue return false, i.e. as expected
  • connectiq-sdk-mac-4.1.3-2022-05-10-b3aaee541: Properties.getValue return TRUE instead of false
  • connectiq-sdk-mac-4.1.4-2022-06-07-f86da2dee: Properties.getValue return TRUE instead of false
  • connectiq-sdk-mac-4.1.5-2022-08-03-6e17bf167: Properties.getValue return TRUE instead of false
  • connectiq-sdk-mac-4.2.0.beta1-2022-10-11-bff57b73c: 'make' fails w/ 'Error 100' and does not provide any further details

Unless I am missing something, this is a bug, which might also be related to:

https://forums.garmin.com/developer/connect-iq/i/bug-reports/bug-boolean-properties-with-default-value-true-can-t-be-changed-in-simulator

https://forums.garmin.com/developer/connect-iq/i/bug-reports/sdk-4-1-1-settings-issues

  • UPDATE 2023-03-02:

    Hello,

    Following up just in case others run into this issue:

    - issue seems to be related to sim only, i.e. works fine on device itself

    - issue is resolved by running sim > File-menu > 'Reset all app data'

    - I am guessing this might be MAC-os related issue

  • Why are you facing this issue? I accidentally stumbled onto your post since I was looking for the www.topessaywriting.org/.../competition website online for some college assignment when I accidentally stumbled upon your post.

  • 1. I use eclipse.

    2.  Recently I have added new language and  it didn't want to show in sim. But after some attempt (killing device  deleting apps ....) I could see it. So there is a cache somewhere.

    btw.

    1. long property names unfortunately cost more, it's not symbol but string

    2. and check name of property to not  repeat the same id on few places (e.g. string and properties) - something strange  can happen then

  • I built+run the sim, and the sim showed what it needs to show when the boolean is set to 'true'; but the default-value in the properties for that boolean was 'false';

    I have then added traces to print what value is retrieved by Toybox.Application.Properties.getValue("somePropertyKey"), and the value was 'true';

    I have then left the code+properties intact, and switched SDK + compile + run and got the results listed above.

    I am therefore assuming this is an SDK issue rather than a sim issue.

    I am not sure how to explain how it works for  - perhaps he uses some old caching i.e. my build script is set to delete the temporary folder the sim (I think) creates whenever it is launched