0

(Novice Android Dev)

I have been working with Google's open source media player seen here . One thing that I did was change the package name and now when I build the app and try it on my device, it gives a corrupt package error. I decided to try and replicate the app by just creating a new project and copying everything however it still produces the same error. If the project builds and produces an APK, then how is the package corrupt?

Any ideas on how to fix this? Not really sure what code I should include. Much obliged.

EDIT I found this error in my install debug gradle

Unable to install C:\AndroidStudioProjects\ArabicReader2\app\build\outputs\apk\app-debug.apk com.android.ddmlib.InstallException: Unknown failure (Error: Could not access the Package Manager. Is the system running?) It then proceeds to lists a bunch of errors ending with

`FAILURE: Build failed with an exception.

  • What went wrong: Execution failed for task ':app:installDebug'.

    com.android.builder.testing.api.DeviceException: com.android.ddmlib.InstallException: Unknown failure (Error: Could not access the Package Manager. Is the system running?)

  • Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.`

Full error here

abbanoob
  • 216
  • 1
  • 16
  • 1
    Have your tried uninstalling the app from your phone? Also close Android Studio and restart it – David Rawson Dec 09 '16 at 22:39
  • The app never actually installs on the phone. It says " Package is corrupt. App was not installed" As far as Android Studio, I have restarted it several times and it cannot even run in the emulator – abbanoob Dec 09 '16 at 22:41
  • http://stackoverflow.com/q/15524185/5241933 – David Rawson Dec 09 '16 at 22:54
  • I fixed something with the Manifest and one of my CastOptionsProvider activities which now allows the emulator to load the app. However when I side load to my own device, the error persists. In other words, the emulator is working but its when I build the APK and try it on my own device – abbanoob Dec 09 '16 at 23:02
  • So I guess I had a different application with the same name back when I was testing something else a while ago. I just uninstalled that other application and it worked. – abbanoob Dec 09 '16 at 23:25
  • Glad you sorted it out! – David Rawson Dec 09 '16 at 23:28
  • Would you like to post the answer to this question? I am trying to get as many reputation points as I can. I am so close to the comment one which I am trying to aim for – abbanoob Dec 10 '16 at 02:46

0 Answers0