Instant Run works but .apk file does not install

0

Well, the problem I'm facing is that when I emulate my app through Instant Run runs perfectly on my > smartphone . However, I can not install the same app via the .apk generated.

Use the Android Studio 3.2.0.0

Note: .apk is generated without errors, but when trying to install it appears: app was not installed.     

asked by anonymous 04.06.2018 / 21:01

1 answer

0

The safest way to generate an APK that will be installed manually (outside of Android Studio) is by using Gradle.

With a terminal open in your project folder, run the following command to generate a new APK:

On Unix: ./gradlew assembleDebug

On Windows: gradlew assembleDebug

Sometimes the APK generated by Android Studio is partial and / or contains the android:testOnly="true" flag in AndroidManifest.xml

    
04.06.2018 / 21:21