Open rstutsman opened 3 months ago
I think this is a Nightscout time formatting bug, not an issue on Tandem's end. Tconnectsync has logic to try two different timestamp formats when querying Nightscout to work around this, so I think this warning can be ignored in your case.
the date/time returned from Nightscout above in the error message is indeed not a valid ISO-8601 datetime
2024-06-13+08:49:09.971622 00:00
according to the spec, the date/time separator should be a T
not the +
and the timezone should be separated with the +
and not a whitespace
2024-06-13T08:49:09.971622+00:00
are we passing the correct date and Nightscout isn't handling it? or are we passing the invalid date and Nightscout is spitting it back verbatim?
are we passing the correct date and Nightscout isn't handling it? or are we passing the invalid date and Nightscout is spitting it back verbatim?
Older versions of Nightscout appear to accept writes via the API into Mongo with invalid-formatted dates. (I don't want to throw any blame here, but it might have been an xDrip+ bug?) This means that in some cases the invalid iso-8601 formatted date needs to be sent in order to properly filter dates. Currently, tconnectsync works around this bug by attempting both the "correct" and "incorrect" formats in sequence, and trying the other if such a http 500 occurs.
i got this warning, twice, and started to dig in
since the error message is last_uploaded_entry with t_to_space
(important part being the t_to_space
), it means that we tried to get the data with the correct datetime format but received a 200 response with zero items
i was able to reproduce the empty list with the offending datetime multiple times but eventually nightscout returned the expected result and i could no longer reproduce :thinking:
It looks like Tandem's API might have changed recently (7.17.2.3) and broken things?
I haven't dug deeper into this yet, but it looks like perhaps the date stamps passed to their server need to be adjusted a bit.