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

Google Drive Backup Function Crashes #416

Open
ghost opened this issue Jun 25, 2018 · 3 comments
Open

Google Drive Backup Function Crashes #416

ghost opened this issue Jun 25, 2018 · 3 comments
Assignees

Comments

@ghost
Copy link

ghost commented Jun 25, 2018

Exception java.lang.RuntimeException: Can't toast on a thread that has not called Looper.prepare()
android.widget.Toast$TN. (Toast.java:390)
android.widget.Toast. (Toast.java:114)
android.widget.Toast.makeText (Toast.java:277)
android.widget.Toast.makeText (Toast.java:267)
android.widget.Toast.makeText (Toast.java:304)
org.glucosio.android.activity.BackupActivity.n ()
org.glucosio.android.activity.BackupActivity.b ()
org.glucosio.android.activity.BackupActivity$7$1.run ()

Possibly Google has deprecated the way @paolorotolo originally implemented Google Drive Backup:
https://developers.google.com/android/reference/com/google/android/gms/drive/DriveApi

@ghost
Copy link
Author

ghost commented Jun 25, 2018

Possibly same issue:
Exception java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
android.os.Handler. (Handler.java:200)
android.os.Handler. (Handler.java:114)
android.widget.Toast$TN. (Toast.java:639)
android.widget.Toast. (Toast.java:131)
android.widget.Toast.makeText (Toast.java:434)
android.widget.Toast.makeText (Toast.java:507)
org.glucosio.android.activity.BackupActivity.n ()
org.glucosio.android.activity.BackupActivity.b ()
org.glucosio.android.activity.BackupActivity$7$1.run ()

@ghost
Copy link
Author

ghost commented Jun 25, 2018

Exception java.lang.NullPointerException: uriString
android.net.Uri$StringUri. (Uri.java:477)
android.net.Uri$StringUri. (Uri.java)
android.net.Uri.parse (Uri.java:439)
org.glucosio.android.activity.BackupActivity$8.a ()
org.glucosio.android.activity.BackupActivity$8.a ()
com.google.android.gms.common.api.internal.BasePendingResult$a.handleMessage ()
android.os.Handler.dispatchMessage (Handler.java:105)
android.os.Looper.loop (Looper.java:156)
android.app.ActivityThread.main (ActivityThread.java:6523)
java.lang.reflect.Method.invoke (Method.java)
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:942)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:832)

@emartynov emartynov self-assigned this Jun 25, 2018
@ghost
Copy link
Author

ghost commented Jul 13, 2018

It doesn't look like any work has occurred on this that said @paolorotolo has agreed to look at it this weekend. It looks like the Google Drive code will need to be replaced as Google deprecated it. Why did it break? Because we updated to newer API level which deprecates it but older API level did not.

I'd love for us to have the discussion of adding login and letting users sync their data to a server we run so this does not continue to become an issue. We can also still offer Google Drive for those who want it!

emartynov pushed a commit that referenced this issue Jul 28, 2018
* Disable 'Backup to Google Drive' function as a hot fix for #416

* Use number formatter to honor locale settings for entry and display, proposed fix for #423

* Increase decimal places shown during mgDl to mmol display, part of overall fix for #423
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant