android / identity-samples

Multiple samples showing the best practices in identity on Android.
Apache License 2.0
366 stars 221 forks source link

Question: what is "Expected BEGIN_OBJECT but was BEGIN_ARRAY at line 1 column 2 path $" ? #24

Closed AndroidDeveloperLB closed 6 months ago

AndroidDeveloperLB commented 4 years ago

I tried to just take the PhoneNumberActivity into an existing project. Made it be able to be built, but then when there was no error anymore in it, I got this weird issue:

image

How come?

nic0lette commented 4 years ago

Looks like it's from GSON, but as for exactly what's wrong I'm not sure. Can you reproduce it with the sample project itself?

AndroidDeveloperLB commented 4 years ago

It's the file from the sample. I've put it into an existing project that already has "google-services.json", but looking at the requirements, I think I still miss some other files for some reason:

image

I only want to get the phone number chooser for the user. Do I have to get more than this file? If so, what else should be used, and how do I get it?

dector commented 4 years ago

@AndroidDeveloperLB Which Android Studio version are you using? I have this issue with Android Gradle plugin 4.0.0-alpha07 on unrelated project. AS 4.0.0 Canary 6 with gradle plugin 4.0.0-alpha06 don't have this issue.

AndroidDeveloperLB commented 4 years ago

I used IDE canary. But now I tried stable too. Seems to work. Even the sample, without any further steps from me. Does it require the json file? more? less? What are the requirements to just show the phone chooser dialog to the user?

ashnohe commented 6 months ago

Closing as issue is no longer reproducible after upgrading & this issue is stale.

AndroidDeveloperLB commented 6 months ago

Meaning it was fixed?