RoboTutorLLC / RTFace_Login

1 stars 1 forks source link

updated RTFaceLogin 1.8.2.2 won't install over old one because "package conflicts with an existing package by the same name" #62

Open JackMostow opened 1 year ago

JackMostow commented 1 year ago

After uninstalling an old version of FaceLogin, RTFacelogin-development-2023-01-19-1.8.2.2.apk installed successfully (using "Install Anyway" to get past Play Protect). However, when I then try to install the updated version RTFacelogin-development-1.8.2.2-20230307_225011.675.apk, "The package conflicts with an existing package by the same name."

I thought we gave it the same version number so that we could just update it without reinstalling it. (How) does updating an app differ from installing its apk?

rishideepc commented 1 year ago

Hello Sir,

I read up on this issue a bit and as far as I understood, "The package conflicts with an existing package by the same name" message indicates that the new APK has the same package name (that is of the form, 'com.example.appname') as the older APK. This similarity in the package names is used by the Android OS to identify the old APK and update it with the new, installed APK.

I'm not entirely sure, but the conflict here seems to be with some pre-existing cache or data of the FaceLogin app on the device. We might have to clear the cache before we proceed with the installation.

Thanks - Rishideep.

On Wed, 8 Mar 2023 at 05:03, JackMostow @.***> wrote:

Assigned #62 https://github.com/RoboTutorLLC/RTFace_Login/issues/62 to @rishideepc https://github.com/rishideepc.

— Reply to this email directly, view it on GitHub https://github.com/RoboTutorLLC/RTFace_Login/issues/62#event-8691473135, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATWQVHKUSFPYA6IXIFX44ILW27ATLANCNFSM6AAAAAAVTDJLOQ . You are receiving this because you were assigned.Message ID: @.***>

JackMostow commented 1 year ago

@rishideepc - Thanks for looking. We want to preserve the user profiles from the prior version, which ara stored in the sqlite database, so if that's what's in the cache, we shouldn't clear it. I don't know where FaceLogin stories the selfie videos and gallery photos -- I'd think in files, in which case I'd hope they'd survive uninstalling the app, but i don't know.

(How) can you find out what's causing the conflict and how to fix it? Do app updates work differently than running the apk?

rishideepc commented 1 year ago

Hello Sir!

I tried running the apk on my emulator, and consequently observed that FaceLogin stores the selfie videos and gallery photos in files, in the sdcard of the device, and yes they survive uninstalling the app, as it is the same place where I dump the 'userProfiles.json' file.

I think according to our app architecture, since we have implemented 'dump and load' in FaceLogin, app updates work no different than running the apk. However, traditionally updating the apk retains the user data, while installing is essentially re-installing from scratch, with no data retention.

I'm not sure how working with the android package name would affect the scenario, but there might be something. I'll look into it, Sir.

Thanks - Rishideep!

On Wed, 8 Mar 2023 at 22:35, JackMostow @.***> wrote:

@rishideepc https://github.com/rishideepc - Thanks for looking. We want to preserve the user profiles from the prior version, which ara stored in the sqlite database, so if that's what's in the cache, we shouldn't clear it. I don't know where FaceLogin stories the selfie videos and gallery photos -- I'd think in files, in which case I'd hope they'd survive uninstalling the app, but i don't know.

(How) can you find out what's causing the conflict and how to fix it? Do app updates work differently than running the apk?

— Reply to this email directly, view it on GitHub https://github.com/RoboTutorLLC/RTFace_Login/issues/62#issuecomment-1460511715, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATWQVHOMO5OGVDCLKASKSGTW3C35PANCNFSM6AAAAAAVTDJLOQ . You are receiving this because you were mentioned.Message ID: @.***>

JackMostow commented 1 year ago

Great, keep me posted. Thanks! - Jack