Why doesn't Android Play Store relaunch my app after an in-app update? - Stack Overflow

My Android app does in-app updates and they've been working fine until the last few weeks. Until r

My Android app does in-app updates and they've been working fine until the last few weeks. Until recently my app would update and get relaunched by the Play Store, but now my app gets updated then its process is killed but there's no relaunch.

This is my call to manage the update.

appUpdateManager.startUpdateFlowForResult(appUpdateInfo, this,
    AppUpdateOptions.newBuilder(AppUpdateType.IMMEDIATE).build())

This is the sequence of events I see during the update flow.

  1. Launch app, app detects an update is available

  2. Launch update flow and go to the Play app

  3. Up until this point I've seen the following lifecycle events

    onCreate()
    onResume()
    onPause()
    
  4. Click on the "Update" button, download gets to 100%

  5. Play Store says "installing...", I see this in LogCat

    PROCESS ENDED (17634) for package com.my.app
    
  6. My app never received

    onStop()
    onDestroy()
    
  7. My app never received another

    onCreate()
    onResume()
    

Is there something new I need to do for in-app updates to work like they used to?

My Android app does in-app updates and they've been working fine until the last few weeks. Until recently my app would update and get relaunched by the Play Store, but now my app gets updated then its process is killed but there's no relaunch.

This is my call to manage the update.

appUpdateManager.startUpdateFlowForResult(appUpdateInfo, this,
    AppUpdateOptions.newBuilder(AppUpdateType.IMMEDIATE).build())

This is the sequence of events I see during the update flow.

  1. Launch app, app detects an update is available

  2. Launch update flow and go to the Play app

  3. Up until this point I've seen the following lifecycle events

    onCreate()
    onResume()
    onPause()
    
  4. Click on the "Update" button, download gets to 100%

  5. Play Store says "installing...", I see this in LogCat

    PROCESS ENDED (17634) for package com.my.app
    
  6. My app never received

    onStop()
    onDestroy()
    
  7. My app never received another

    onCreate()
    onResume()
    

Is there something new I need to do for in-app updates to work like they used to?

Share Improve this question asked Mar 13 at 4:28 BunglesBungles 2,2752 gold badges33 silver badges62 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

you must check which result you are getting first: RESULT_OK, RESULT_CANCELED or ActivityResult.RESULT_IN_APP_UPDATE_FAILED

For immediate updates, you might not receive RESULT_OK callback because the update should already be finished by the time control is given back to your app.

When you call appUpdateManagerpleteUpdate() in the foreground, the platform displays a full-screen UI that restarts the app in the background. After the platform installs the update, your app restarts into its main activity.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744720531a4589880.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信