Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App force update #489

Open
atheer10 opened this issue May 1, 2024 · 15 comments
Open

App force update #489

atheer10 opened this issue May 1, 2024 · 15 comments
Assignees
Labels
investigating We are investigating the current problem new

Comments

@atheer10
Copy link

atheer10 commented May 1, 2024

Describe the bug & problem

We are trying to force update in our game, we have looked into the documentation , and we have integrated the the update SDK in our game prior.
We have released a new version to the store, and we are testing with an older version to see if the pop-up appears but it doesn't. Both versions when released "force update" button on the Huawei AppGallery was turned on, our understanding is there's no additional calls required or steps aside from the integration and store check.

When we visit the store, we can see that an update is available.
When the auto-update for the store was on, the app updated on it's own, we have turned it off in order to test, but the no results.
Currently, we do not see the force update pop-up panel or any indicator that the update sdk is working.

We have provided screenshots of the code, Can you please guide us to any missing steps ?

Expected behavior
A new version is available pop-up shows up when the game is booted.

Screenshots & Detailed log
If applicable, add screenshots and a Log to help explain your problem.

image (2)
update_huawei_3
update_huawei_2
update_huawei_1
update_huawei
update_huawei_4

Environment (please complete the following information):

  • Unity Version [2021.3.22f1]
  • HMS Unity Plugin Version [2.3.4] (we cannot update it as it creates many issues with our integrations

Smartphone (please complete the following information):

  • Device: [e.g. Huawei, Non-Huawei, Cloud Debugging]
    Huawei

Additional context

Copy link

github-actions bot commented May 1, 2024

Thank you for reporting this issue/advice.

We will get back to you as soon as possible.
Would you like to star our plugin to support us? ✨

@github-actions github-actions bot added the new label May 1, 2024
@alihan98ersoy alihan98ersoy added the investigating We are investigating the current problem label May 2, 2024
@Andronovo-bit
Copy link
Collaborator

Hi @atheer10 . We are under review. If you want, you can try the suggestions below until this process is complete.

  • Can you try to make it "true" this line? (HMSGameManagerService.cs) (After this update, you may need to do an update to try this code.)

K2xjw8o87t

  • Did you release a new version directly or did you try it using a closed test?

@atheer10
Copy link
Author

atheer10 commented May 5, 2024

@Andronovo-bit

  • Have created a build with that fix, will keep you updated on the results once it is approved from the store.

  • No, we have always created a new release version, as the option for force update is not available on closed testing.

@atheer10
Copy link
Author

@Andronovo-bit
We have created a new build with the fix above of changing the CheckAppUpdate values to true and installed it on the device, then uploaded another newer version to the store, we can see from the store/notification that there's an update available, however nothing shows up within the app to prompt an update.

@Andronovo-bit
Copy link
Collaborator

@atheer10
Ok I understood. I should have asked before. Did you activate the game service on AppGallery panel ? And also, did you enable gamekit in unity-plugin? Like the below images.

image

image

image

Do you mind if can you send a game url or apk for review?

@atheer10
Copy link
Author

@Andronovo-bit
Looks like those settings were off ! I will make a new build and share it
This is the URL of the game : https://appgallery.huawei.com/app/C105911883

@Andronovo-bit
Copy link
Collaborator

Andronovo-bit commented May 20, 2024

I tried to download this app, but I couldn't see it in the gallery. Is released this app or can we accessable in Turkey ? I guess this game don't available in my region.

@atheer10
Copy link
Author

@Andronovo-bit

  • We a made two new releases with the game services enabled both in Unity project and in app gallery, but the pop-up doesn't show up. We get a notification that there's a new update as shared above, but no in-game pop-up.

  • Yes, the game is not available there, I will update the release to include it.

@Andronovo-bit
Copy link
Collaborator

@atheer10

  • Okay, we wait for release in our region to test your application.

  • Can you share the log records of the scenario where the update popup should appear in our application?

@atheer10
Copy link
Author

atheer10 commented Jun 2, 2024

@Andronovo-bit

  • We've updated the app and added Turkey, you should be able to find it in the App Gallery store. We will release a newer update so we can test the force update function .
  • In terms of where it should appear, since the logic is mostly in the awake, and init methods, it should appear at the loading screen of the game.

@Andronovo-bit
Copy link
Collaborator

Andronovo-bit commented Jun 3, 2024

@atheer10

Hi, thank you for opening your game in Turkey. We checked the game with logs, but we didn't see any "game service and update function triggered" logs. You should enable game service and use HMSGameServiceManager for force updating.

For instance;

If you want to use it in a starting scene, you can add the below code.

HMSGameServiceManager.Instance.InitGameManagers()
HMSGameServiceManager.Instance.CheckAppUpdate(true,true)

OR

If you already use HMSGameServiceManager in your scene, you can change the InitGameManager's function's body like below.


 public void InitGameManagers()
     {
             ...
             ...
            CheckAppUpdate(true, true);
      }

After calling this function, you will be automatically callback to the 'OnUpdateInfo' methods in HMSGameService and the Update Dialogue will be opened in your game.

@atheer10
Copy link
Author

atheer10 commented Jun 9, 2024

@Andronovo-bit

  • Correct , there was a setting that was turning off the game service, we enabled that again and just released a new version 4494, but perhaps it's not going to show as there's no newer version yet.
  • We are using the second method to call the update

image
image

@Andronovo-bit
Copy link
Collaborator

Andronovo-bit commented Jun 10, 2024

  • It looks everthing is OK @atheer10, on code side. If you enabled the Game service and used it at startup, everything is OK.
  • After this code releasing, if you do new update we can see what's going on background in log records.

@atheer10
Copy link
Author

atheer10 commented Jul 3, 2024

@Andronovo-bit
We have a newer release with those implemented, and we still don’t see the update prompt. Do you mind looking at the logs to see why ?

@Andronovo-bit
Copy link
Collaborator

@atheer10 Hello again,

We checked it but we didn't find any game service log record in Logcat.

For example, we able to see IAP kit log records like this;

image

But we can't see any game service log record like this;

image

You didn't enable or initialize the game service kit in your project start, as we can see.

You should trigger game service kit during game starting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
investigating We are investigating the current problem new
Projects
None yet
Development

No branches or pull requests

3 participants