Skip to content
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

Library gets time but is not saved nor persistent #11

Open
agforte opened this issue Apr 30, 2020 · 0 comments
Open

Library gets time but is not saved nor persistent #11

agforte opened this issue Apr 30, 2020 · 0 comments

Comments

@agforte
Copy link

agforte commented Apr 30, 2020

When the application first starts it says:

W/Persistence: not providing a Context to access SharedPreferences disables most of Persistence's features!
I/Persistence: instance:com.medavox.library.mutime.Persistence@be0eb7b
W/Persistence: no time data in memory, attempting to retrieve from SharedPreferences...
E/Persistence: Time Data was found to be invalid when checked! stored clock offset: 1020; stored uptime offset: 1587744810916; live clock: 1588274998296; live uptime: 46205117; Stored Clock difference: 1587744809896; live Clock difference: 1588228793178

then it tries to get time from network:

I/Ntp: Getting the time from 8 IP addresses: [time.google.com/216.239.35.12, pool.ntp.org/162.159.200.123, time.google.com/216.239.35.8, pool.ntp.org/193.29.63.150, time.google.com/216.239.35.4, pool.ntp.org/23.31.21.163, pool.ntp.org/66.228.59.187, time.google.com/216.239.35.0]...

After many NTP poll timeouts (?) the library finally gets the time:

Ntp: got time data "TimeData [Round Trip Delay: 62; System Clock offset: 184; Device Uptime offset: 1588228793362]" from 23.31.21.163

However, the next time I try to get the time from the library I get:

W/Persistence: no time data in memory, attempting to retrieve from SharedPreferences...
W/MuTime: Could not get current time.

and then after many of such lines above I get:

 W/System: A resource failed to call close. 
 I/chatty: uid=10135(com.cyphme.cyph) FinalizerDaemon identical 13 lines
 W/System: A resource failed to call close. 
 W/System: A resource failed to call close. 
 W/Persistence: no time data in memory, attempting to retrieve from SharedPreferences...
 W/MuTime: Could not get current time.
 W/System: A resource failed to call close. 
 I/chatty: uid=10135(com.cyphme.cyph) FinalizerDaemon identical 6 lines
 W/System: A resource failed to call close. 
 W/System: A resource failed to call close. 
 W/System: A resource failed to call close. 
 W/Persistence: no time data in memory, attempting to retrieve from SharedPreferences...
 W/MuTime: Could not get current time.

It looks pretty messy. Anybody has any idea on what's happening here?
Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant