12-02-2017 09:21
12-02-2017 09:21
I can successfully write files and read them, but I am running into some issues.
When I read the stats, the date is completely off. I am about 30 days in the future. I think it also creates issue with app not reading the new files generated by the companion, as it does not see it as new.
I am using the basic stats code as from the documentation:
let stats = fs.statSync("tides.txt"); if (stats) { console.log("File size: " + stats.size + " bytes"); console.log("Last modified: " + stats.mtime); }
- Also, is there a way to write a file for the clock face, and have different apps access it? That way it does not need to be created for each app all the time.
12-04-2017 09:43
12-04-2017 09:43
That's strange. We'll look into this one for you. Thanks!
12-04-2017 10:07 - edited 12-04-2017 16:09
12-04-2017 10:07 - edited 12-04-2017 16:09
@JonFitbit while you are looking into it, I noticed another weird behavior/bug.
I have the same code for one App and one Watch Face. The App updates the file and reads it, updating info. The watch face only does it when connected through the studio. Otherwise it won't read/fetch new data.
EDIT - Same exact code. Copied and pasted. App fetch new data and write a file, refreshing it as time goes by.. Watch face doesn't.
12-27-2017 06:48 - edited 12-27-2017 06:49
12-27-2017 06:48 - edited 12-27-2017 06:49
Hi Jon,
This behaviour still exists:
rhrData.cbor info: File size: 249 bytes Last modified: Sat Jan 27 2018 13:35:30 GMT+11:00
stats.mtimeis returning a month, minus half a day in the future
stats.mtime: Sat Jan 27 2018 13:35:30 GMT+11:00 now: Thu Dec 28 2017 00:38:02 GMT+11:00
04-04-2021 13:11 - edited 04-04-2021 13:13
04-04-2021 13:11 - edited 04-04-2021 13:13
stats.mtime is showing about 38 hours ahead for me.
example:
unix timestamp when file was created 1617564380
stats.mtime shows: 1617696648
the difference is 132268 seconds
just to confirm, the mtime was a future date of around 38 hours ahead which had not yet been reached, so it can in no way be caused by the file being unknowingly modified
using SDK 4.2.2
04-28-2021 08:03
04-28-2021 08:03
Has there been any progress on this bug?
04-30-2021 06:00
04-30-2021 06:00
The original ticket had been closed since they'd been unable to reproduce it.
Can you check something for me. Reboot your watch and try creating a new file.
Does the problem still exist?
Thanks