Why Android studio won't run app on Android Pie (9.0)?
Asked Answered
S

6

14

I've upgraded my Google Pixel to Android 9.0/Pie. When I try to run an application from Android studio I don't see the Google Pixel in the list, there's only a null device named FA69R0306649. When I run my application, Android studio tries to install the app but then fails.

It looks like Android Studio is not recognizing the phone anymore. It Worked perfectly fine a couple of hours ago under Oreo (8.x).

Also, if I deploy the app on google play as alpha and then download it runs perfectly under 9.0/Pie.

Any suggestions to get the run/debug working with android 9.0 phone under Android Studio (3.1.4)?

Demo image

Spurlock answered 13/8, 2018 at 19:31 Comment(17)
is usb debugging enabled?Cornhusk
What version of java are you running?Lourdeslourie
/opt/android-studio/jre/bin/java -version openjdk version "1.8.0_152-release" OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01) OpenJDK 64-Bit Server VM (build 25.152-b01, mixed mode) java -version openjdk version "10.0.1" 2018-04-17 OpenJDK Runtime Environment (build 10.0.1+10-Ubuntu-3ubuntu1) OpenJDK 64-Bit Server VM (build 10.0.1+10-Ubuntu-3ubuntu1, mixed mode)Spurlock
Debug is enabled (also re-generated the security certs). It works fine with my other mobiles (6.0, 8.1). It worked fine with the pixel till I updated it from 8.1 to 9.0.Spurlock
Can you check for update in android studio, I've just seen that this could be a driver issueLourdeslourie
What's your gradle version?Lourdeslourie
Android studio is the latest version: 3.1.4.Spurlock
Gradle Version: 173.4301.25Spurlock
Can you try to run a virtual device with android 9.0 and see if it works? This would get out of the way the hypothesis of AndroidStudio being the problemLourdeslourie
Aslo can you open your phone files from usb or is it completely jammed?Lourdeslourie
Can open phone files, can transfer files, USB is def recognised. If I switch off USB debugging it disappears in Android Studio and when I re-enable it it's back. Just downloading latest Pixel emulator with API28. Bear with me.Spurlock
Just running the app via the emulator with API28 (Pie) and it all works perfectly fine.Spurlock
Installing the emulator didn't change the phone behaviour? If no I've run out of idea...Lourdeslourie
Installation of the emulator didn't change anything. I suspect that Android Studio just won't recognise the phone just now. Which is weird as it's a google (!) one.Spurlock
I think I know what it is. It's the certificate. It seems so that 9.0 just won't ask for a new certificate even when I revoke it and/or delete the adbkey. Just out of interest I've deleted ~/.android/adbkey* and all phones prompt for new security certs but not Android 9.0. So no chance to connect to it via adb.Spurlock
Done factory reset of the Pixel but it still won't ask for a security certificate.Spurlock
Definitely a problem with Android Studio, we need to report this as a bug on their site. I've done so and suggest everyone to as well, follow this link for information: developer.android.com/studio/report-bugsPsoriasis
S
3

The Pixel running 9.0 requires USB 2.0 high speed. Apparently the Pixel running Android Pie cannot talk to the PC using neither USB 3.0 nor USB 1.1 full speed nor USB 2.0 running at full speed.

Spurlock answered 1/9, 2018 at 19:23 Comment(5)
Actually, for me it was the other way around. I tried with a powered USB hub and it did work... but the direct cable to my laptop didn't, because it was USB 3. Just crazy! I guess the fact that it is powered made the difference.Crunode
I'd be curious @Crunode if your USB hub is a USB 2.0 or USB 3.0.Spurlock
It appears to be that we need actually USB 2.0 high speed. Turned out that I have a fake USB 2.0 hub which actually only does full speed but not high speed. I replaced it with a proper USB 2.0 hub and now I can use the hub.Spurlock
You may want to edit your answer with that informationCrunode
That bug blew my mind!! it works on USB 2.0 , i'm Android One and just got the update yesterday!Halmstad
A
3

I had a similar problem with my Xiaomi Mi A1. When I upgraded from Android 8.1 to 9 Android Studio would hang on "Installing application" forever. After trying revoking USB debugging authorization and completely reenabling developer options with no success it turned out a simple restart did it. Looks like there are multiple issues that lead to the same problem.

Arthurarthurian answered 3/1, 2019 at 20:21 Comment(3)
The same problem occurs for me. After Restart Its work perfectly for me.Sanorasans
restart is great, however, what is the configuration of the phone.Basically
What exactly do you mean by configuration of the phone?Arthurarthurian
W
1

I had the same issue with a Xiaomi Mi A2 after upgrading to Android 9. If you are using Linux, try adding the udev permissions manually, following the steps described here. In my case, that was the only solution that worked.

Weirick answered 17/12, 2018 at 8:59 Comment(0)
O
1

Please re-enable developer options again after the OS version upgrade, the device name will appear and it will be working fine again

Overlarge answered 23/1, 2019 at 6:53 Comment(0)
L
0

Install Sdk Platforms of Android 9. In Android studio Top Right besides Search Icon.Press That Icon of SDK manager and look either sdk platform is updated and installed.

Lashandralashar answered 4/10, 2019 at 9:23 Comment(0)
W
-1

A simple solution just go to your Developer option on your phone , right below the USB Debugging option it says to "install via USB" just enable it and you are all set to install an app through android studio into your 9.0 device.

Wimmer answered 24/7, 2019 at 18:7 Comment(1)
"install via usb" is not a PIE optionBasically

© 2022 - 2024 — McMap. All rights reserved.