timoschlueter / nightscout-librelink-up

Script written in TypeScript that uploads CGM readings from LibreLink Up to Nightscout.
MIT License
189 stars 246 forks source link

Error message can provide more info about what caused the issue #156

Open aleb opened 1 week ago

aleb commented 1 week ago

https://github.com/timoschlueter/nightscout-librelink-up/blob/270107ffe9a91363024e0715caf30ce7de851783/src/nightscout/apiv1.ts#L59

The error message can appear like "Upload to NightScout failed failed to post new entries: undefined". It would be useful to include the error code as that has a precise meaning.

https://axios-http.com/docs/res_schema even says "As of HTTP/2 status text is blank or unsupported".