Android INSTALL_FAILED_UID_CHANGED

前端 未结 26 1211
走了就别回头了
走了就别回头了 2020-11-28 07:37

I have been doing debugging on Android using my Nexus 4, however I recently encountered this error here. After doing some research on this error, it seems to be an issue wit

26条回答
  •  情深已故
    2020-11-28 07:59

    I found a solution that works both on a non-rooted device and on an emulator. While you can't directly delete the data folders on a non-rooted device you can utilize the pm command to do that:

    1. Run adb shell
    2. Run pm uninstall (i.e. com.example.myapp)
    3. Run pm uninstall (i.e. com.example.myapp.test) - you might receive an error if the test app wasn't installed before.

    It seems that for some reason when uninstalling the apps from the Android UI this doesn't work (possibly it doesn't delete the data folders) however when uninstalling via the pm command it does work.

    Tried it on a "Nexus 5" and on a "OnePlus One".

提交回复
热议问题