Xdrip: Nightscout treatments are not downloaded

Created on 6 Feb 2020  路  6Comments  路  Source: NightscoutFoundation/xDrip

Treatments entered in XDrip are shown on the master and in the Webinterface, but not on the Noghtscout Follower. "Download Treatments" is turned on.
But when a treatment is entered in the Webinterface is shows up on the follower, as can be seen in the attached image.
nightscout
xdrip follower

bug sync-nightscout

Most helpful comment

From my brief and uneducated quick scan of Treatments.java, it does indeed appear as though the "Entered By" record is taken from a hard-coded constant (XDRIP_TAG) that currently cannot be changed in the app.

Also, looking at NightscoutTreatments.java (and this is my best interpretation as a hobbyist's first look) - at line 133, it looks like a check on new treatments to only process non-existing (i.e. new) treatments not coming from xdrip (i.e. "Entered By" is not "xdrip"). There's a else condition block to catch changes for pre-existing treatments whether or not they come from xdrip, but there does NOT look to be any code to process new treatments that come from xdrip. Seems to me like this is the root cause of the issue we're describing.

I'd suggest possibly adding a configurable setting to allow user control over the XDRIP_TAG contents, but have no idea what other negative effects this may have elsewhere. It may be easier to avoid downloading/uploading duplicates if all XDrip users syncing to a Nightscout instance could have treatments uniquely identified via the XDRIP_TAG.

Alternatively, perhaps non-existing treatments could be process whether or not they came from xdrip?

Lastly - this may be a duplicate of #1196. Possibly related to #735, but maybe not.

All 6 comments

Same for me here

Treatments entered in XDrip are shown on the master and in the Webinterface, but not on the Noghtscout Follower

It is still not working. Is this a xdrip issue or a nightscout issue?
This seems to be the only way (if it would work) to distribute treatments for people with phones that have no play services installed and can't use the sync featue.

Hello,
Yes if someone can help debugging ?
I can give all informations if needed
Thanks

Having the same issue on several phones running XDrip

Edit: Interesting note. When looking at the treatment history/database in Nightscout, I see that all the treatments entered from the xdrip app have "xdrip" in the "Entered By" field. In Nightscout, I can manually edit the treatment data, so I tried changing "xdrip" to something else, and afterwards, my XDrip app downloaded that specific treatment.

So, it seems like the issue here is the "Entered By" field used to upload the treatment data. If all phones' XDrip apps are using "xdrip", perhaps they're intentionally ignoring those treatment records, with each app assuming it was the uploader?

Is there anyway to customize or configure XDrip as far the treatment's "Entered By" record?

From my brief and uneducated quick scan of Treatments.java, it does indeed appear as though the "Entered By" record is taken from a hard-coded constant (XDRIP_TAG) that currently cannot be changed in the app.

Also, looking at NightscoutTreatments.java (and this is my best interpretation as a hobbyist's first look) - at line 133, it looks like a check on new treatments to only process non-existing (i.e. new) treatments not coming from xdrip (i.e. "Entered By" is not "xdrip"). There's a else condition block to catch changes for pre-existing treatments whether or not they come from xdrip, but there does NOT look to be any code to process new treatments that come from xdrip. Seems to me like this is the root cause of the issue we're describing.

I'd suggest possibly adding a configurable setting to allow user control over the XDRIP_TAG contents, but have no idea what other negative effects this may have elsewhere. It may be easier to avoid downloading/uploading duplicates if all XDrip users syncing to a Nightscout instance could have treatments uniquely identified via the XDRIP_TAG.

Alternatively, perhaps non-existing treatments could be process whether or not they came from xdrip?

Lastly - this may be a duplicate of #1196. Possibly related to #735, but maybe not.

This is a duplicate of #1196. The problem reported with #735 is that treatments entered by followers are not uploaded to nightscout.

@jamorham Please can you close this issue?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

dlopez1984 picture dlopez1984  路  6Comments

exceter picture exceter  路  4Comments

tynbendad picture tynbendad  路  19Comments

ArkonPhoenix picture ArkonPhoenix  路  4Comments

opalex84 picture opalex84  路  14Comments