-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error on empty nightscout instance (glooko) #9
Comments
Actually, I also get this issue when there are entries on nightscout already. I'm having a hard time to pin this down due to the "machines" architecture, but I guess this means the Solution is probably just a different check à la - var last_mills = Math.max(two_days_ago, last_known.entries ? last_known.entries.getTime( ) : two_days_ago);
+ var last_mills = Math.max(two_days_ago, last_known && last_known.entries ? last_known.entries.getTime( ) : two_days_ago); But it seems odd that nightscout-connect/lib/machines/fetch.js Line 25 in 8f2ab37
Logs leading up until the NPE btw:
|
Yes, I think Sulka has some patches that help with this. |
Glooko patches from Sulka have been integrated and released. Hope this helps! |
Will check, thanks 🙏 |
Seems like this still happens with the latest version (0.10.0) of nightscout-connect:
|
The following code throws an error if running the connect plugin with glooko credentials on an empty nightscout instance, I assume because there is no
last_known
yet.https://github.com/nightscout/nightscout-connect/blob/8f2ab374a288f8541b916d92cecfb55bb5f44889/lib/sources/glooko/index.js#L85C22-L85C22
The text was updated successfully, but these errors were encountered: