playgameservices / play-games-plugin-for-unity

Google Play Games plugin for Unity
Other
3.44k stars 959 forks source link

Play services error SNAPSHOT_CONTENTS_UNAVAILABLE #3053

Open Kryloth opened 2 years ago

Kryloth commented 2 years ago

Hello, i'm having this weird error every time i'm saving and opening the save data to google cloud save A few information, the save data has worked before I didn't change any code, and I didn't touch the save system anymore because it was working and it has worked 2 days ago when i played the game but now i got this weird code

I looked everywhere on google but it seems there is no information regarding the error code which is 26572 and the only information i got from google game client status code this link here is just

public static final int SNAPSHOT_CONTENTS_UNAVAILABLE An error occurred while attempting to open the contents of the snapshot. See the device logs for more details. Constant Value: 26572

This doesn't help at all, see the log below


[Play Games Plugin 0.10.12] 08/01/21 3:05:16 +07:00 DEBUG: InternalOpen has failed: com.google.android.gms.common.api.ApiException: 26572: SNAPSHOT_CONTENTS_UNAVAILABLE
System.Action:Invoke()
GooglePlayGames.OurUtils.PlayGamesHelperObject:Update()

InternalError
GPGS_Authentication:AfterLoad(SavedGameRequestStatus)
System.Action`1:Invoke(T)
System.Action`2:Invoke(T1, T2)
System.Action:Invoke()
GooglePlayGames.OurUtils.PlayGamesHelperObject:Update()
Kryloth commented 2 years ago

Sorry i misclicked and closed it accidentally...

adbourdages commented 2 years ago

I think this might be related: I'm suddenly getting InternalError when trying to access save files: Google Saved Game - Operation OPEN for save (saveSlot0) failed with error InternalError. This is on a live game that was not exhibiting this issue when the last update was released.

So far I can replicate on a test device. I'll do further testing but wanted to add to the original post.

adbourdages commented 2 years ago

A little bit more information. With two devices connected to the same Play Games account, one is showing InternalError and the other works flawlessly. The problematic device is on Android 12 (API-31) and the other is Android 11 (API-30).

However, a player is having the same problem on API-30, so it probably doesn't have anything to do with it.

Kryloth commented 2 years ago

Huh now that i think about it, this error appears right after I installed an android emulator (Nox Emulator) on my pc and login to my google play account and tested the game on the emulator The game works flawlessly as expected on the emulator, but the day after I login my account on the emulator, the game on my phone throws that error

How in the world does connecting 2 devices with the same account throws an error when it's the point of having a cloud saving system in the first place...

smile616 commented 2 years ago

Can you share your game package name, please?

smile616 commented 2 years ago

also could you please execute the following for the affected device: adb root adb shell setprop log.tag.Volley VERBOSE adb reboot

and see if logcat show any Volley errors. URL + error code would be enough. (Please, remove any auth tokens if copy-pasting logs here)

adbourdages commented 2 years ago

Before running the adb commands, I ran a test to see if there would be any Volley errors. There are none, probably as expected.

However, I just noticed the following line in the log W/PlayGamesServices[PgsSnapshotAgent]: Failed to open snapshot file myMainSaveSlot status: 4002 that has previously escaped my attention. I can barely find any mention of that error code when searching.

adb root results in adbd cannot run as root in production builds. The phone is not rooted.

The package name of the game is com.greencod.pinballdeluxereloaded

Kryloth commented 2 years ago

I don't know what a Volley is but there are several Volley log, but none of them are error code

Same as adbourdages, I had the same error PlayGamesServices[PgsSnapshotAgent]: Failed to open snapshot file PokeTheCat_SaveData status: 4002

The package name for the game is, com.extralife.projectcat

smile616 commented 2 years ago

Thank you, @adbourdages and @Kryloth.

lb4business commented 2 years ago

I have the same issue. "Failed to open snapshot file AUTO_SAVE_NAME status: 4002" After that,
OnSavedGameOpenedAuto(SavedGameRequestStatus status, ISavedGameMetadata game) returns status = InternalError, and metadata is null. It began a couple of days ago, with plugin v.0.10.12 and 0.9.64

One more thing I noticed: After I re-install the game saved games created before reinstall cannot be loaded with error 4002. However, saved games created after reinstall are working. If I reinstall the game again, previously created games are not working again. So only saved games created by the currently installed game are working properly.

package name com.lb4business.swordsbowsmagic

VTeselkin commented 2 years ago

Hi everyone. Has the same problem. Synchronization with the cloud stopped working for some users. We see an error in the logs:

DEBUG: InternalOpen has failed: com.google.android.gms.common.api.ApiException: 26572: SNAPSHOT_CONTENTS_UNAVAILABLE

At the same time, the number of requests to the server increased due to such users. Is there any solution or ideas why this could happen?

Kryloth commented 2 years ago

This seems like a problem with the Play Service itself, do we really have no idea about what caused it still ?

smile616 commented 2 years ago

@VTeselkin, @adbourdages, @lb4business, @Kryloth, thank you for the reports.

We are investigating the issue on the Play Service side. Would it be possible to share bugreports and/or stable steps to reproduce the issue with us? Preferably link to a Google Drive folder but, please, don't accept access request unless it from @google.com email addresses.

adbourdages commented 2 years ago

@smile616 unfortunately there is not much to share. There are no indications of what makes a device throw the error. So far it has been reported from few devices only. However it must be quite common since one of the test devices (fortunately!) does exhibit this issue.

As for bug reports, well, everything we have has been mentioned in this thread. In understand it is frustratingly however. If you desire a full log dump from the test device, no problem.

smile616 commented 2 years ago

@adbourdages yes, please, that will be very helpful! Please see https://developer.android.com/studio/debug/bug-report

Also is affected test device rooted?

adbourdages commented 2 years ago

Here is the link to the bugreport: https://drive.google.com/file/d/1_NdIl4bdhm24hlXXwnPi7amQ1r7nOoV5/view?usp=sharing

The device is not rooted.

smile616 commented 2 years ago

Thank you, @adbourdages. Sent access request.

smile616 commented 2 years ago

@adbourdages, thank you, the bug report was very useful. We've applied some steps on the Play Service side that should mitigate the error rate. I keep the issue open for monitoring.

adbourdages commented 2 years ago

Awesome!

It looks like my test device doesn't throw the InternalError anymore, that's quite a fast resolution, well done!