3

I have an android app which is published on play store. Am trying to implement in App update and test it using android internal track sharing.

For sharing on internal track i tried following and everything gave me same results. 1. Created Apk. Signed with release key of the application 2. Created aap bundle. Signed with release key of the application 3. Created Apk . kept it in debug mode without signing 4. Created aap bundle. kept it in debug mode without signing.

In all above scenarios after uploading the application on internal test track and downloading from the url following consistent behavior is noticed.

  1. appUpdateInfoTask.addOnSuccessListener is called on application launch
  2. appUpdateInfo.availableVersionCode() returns the version code of internal test track app instead of update available on production.
  3. appUpdateInfo.updateAvailability() returns update unavailable.

Alongwith this in logcat we get following point of interest logs.

(app package name) is installed but certificate mismatch.

my code for app update is as followed.

    private void checkforappupdate() {

        Log.v("oneteamlive",".........checking for application update....");
        // Creates instance of the manager.
        AppUpdateManager appUpdateManager = AppUpdateManagerFactory.create(this);

        // Returns an intent object that you use to check for an update.
        Task<AppUpdateInfo> appUpdateInfoTask = appUpdateManager.getAppUpdateInfo();

// Checks that the platform will allow the specified type of update.s
        appUpdateInfoTask.addOnSuccessListener(
                appUpdateInfo -> {
                    Log.v("oneteamlive","in app update info listenere");
                    Log.v("oneteamlive","Available version code is:"+appUpdateInfo.availableVersionCode());
                    Log.v("oneteamlive","Available version code is:"+appUpdateInfo.updateAvailability());
            if (appUpdateInfo.updateAvailability() == UpdateAvailability.UPDATE_AVAILABLE)
                     {
                // Request the update.
                         Log.v("oneteamlive","A new update is available");
                         Toast.makeText(this,"A new update is available",Toast.LENGTH_LONG).show();
            }
            else
            {
                Log.v("oneteamlive","no app update is available");
            }
        });
    }

I have double check that my playstore is completely closed and update is available with higher version code on playstore.

Anybody else also faced similar issues ??

dexprab
  • 89
  • 1
  • 1
  • 3

2 Answers2

0

I have exactly the same issue, and I wonder if it is due to the internal test track's app being resigned by google. Apparently internal sharing's apps are being resigned based on: https://support.google.com/googleplay/android-developer/answer/9844679?hl=en&visit_id=637491136221021613-3110759148&rd=1 but for internal test track, when I download the app, I can see the public cert matches exactly with the apk I had created before uploading to google play store.

Sinapse
  • 143
  • 1
  • 11
0

I am having the same issue, but with InApp reviews. Here are the errors I am getting:

07-09 10:36:19.834  8532 11374 I Finsky  : [27174] fki.<init>(18): com.marcetown.myapp is installed but certificate mismatch
07-09 10:36:19.962  8532 11214 E Volley  : [27115] doi.a: Unexpected response code 404 for https://play-fe.googleapis.com/fdfe/allowInAppReview?doc=com.marcetown.myapp

I feel like this is my issue. I have not done this: enter image description here

I found this on the link Sinapse sent. I will try and update my comment with my results. Thank you Sinapse, at least you gave me a place to look at.

@Edit My issue is that I was using Internal test instead of Internal app Sharing https://play.google.com/console/u/0/internal-app-sharing/ Probably not the same as you, but I would check the certificate image I attached and make sure you have it setup properly.

Marcelo
  • 217
  • 1
  • 2
  • 11