This 2 lines:
This 2 lines:
This issue was recently filed as WERETECH-10767 for this post. The issue has been triaged, but has not been fixed.
You should be able to work around the problem by catching the UnexpectedTypeException in you app code.
Thank you for your replay. I have related issue with SensorHistoryIterator.getMax() function:
- documentation describes that is should return a Number:
getMax() ⇒ Toybox.Lang.Number
while an example shows an SensorSample object:
System.println(sensorIter.getMin().data);
Non of this seems to work on device (fenix5s).
I tested it on device and in my case (fenix5s, getPressureHistory with :period attribute) getMax () function returns something which is not null nor Number. It doesn't pass this statements:
I am sure that Iterator is not null - I got a proper value via iter.next() function, so getMax should return a proper value.
Please post a bug report in the Bug Reports area. I've stopped moving posts from Discussion because they tend to lose replies.