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
Stuck in serverside conflict loop until google play services app data is cleared #1262
Comments
|
After repeatedly resolving a conflict from the open metadata callback (for over 15 minutes), google play services crashed, and we found the following in the logs: The lines of most interest are from lines 266-326. They don't really mean too much to us, but maybe it will help someone else to point us in the right direction? Getting quite desperate on our end, lots of users being unable to play our game and leaving bad reviews as a result, so would appreciate a prompt response :( |
|
Does this fit your experience, or is it somehow different issue? #1204 We are going for an opt-out button in next update (conflict will give them choice of keeping server copy, which usually ends up in loop, local copy that ends up in either loop or wipe, and finally disabling the cloud completely so the game can at least start) as the customers are pretty furious about this. Knowing it before, we would just make cloud save opt-in in a first place, so it wouldn't affect unexperienced users by any means. Now it's too late and we don't wanna risk data wipe for existing cloud users by turning it off by default. |
|
Hi JohnyGQD. Yes that does look like the same issue we're having, I work with miracle7. I wonder how widespread this issue is. We'll continue looking into it. Please let us know if you find a cause/solution. |
|
I'm having this issue too, bump. |
|
@JohnyGQD For us it doesn't seem to matter whether we choose to resolve using the base or conflicting version of the save, it can get stuck in a loop either way (though not consistently). Also as far as I know we haven't ever had a save wiped during the conflict resolution process. For some reason it seems that even if only playing on one device you can end up with conflicts too which doesn't make sense. Was thinking perhaps we were opening the metadata twice or something so google's server treats the one phone as two devices, but investigated that and we definitely only open it once, either when the app opens or after a save (which supposedly closes the metadata). |
|
During my debugging session, I end up with having ReadNetworkOnly everywhere, saving with automatic resolution as UseUnmerged and loading with manual resolution. I wasn't able to reproduce it with this configuration, but kept the opt-out button anyway. Just in case.. |
|
Okay, we still get stuck in this conflict loop regardless of whether we use ReadNetworkOnly or ReadCacheOrNetwork, so musn't be that. Not sure what you mean by saving with UseUnmerged as you cannot save with a conflict resolution policy or anything like that, only when you open metadata. We were able to view our games app data directory on Google Drive, and found there were only 2 conflicting saves rather than a large list of them, which implies that the conflict resolution isn't being applied rather than us generating multiple conflicts and trying to get through them all. Upon uninstalling and reinstalling our app, the loop also seems to disappear, but not when clearing the apps data on the phone, which makes it seem like google play services is hanging onto some corrupt conflict data that it associates with that install. We keep the metadata open wherever possible so we can commit an update without having to wait for the metadata to open first, which is impossible to do in the one frame that we are given on application pause/quit. We noticed that sometimes when you open the metadata as soon as the save callback comes back, the save the server gives us is one behind the one that we just uploaded. Not sure if we should be waiting some amount of time before re-opening or something like that, but we assumed that all serverside operations would be complete if we are receiving that callback. |
|
It seems like you're having the same problem as we do. The following happens:
this.playGamesClient.OpenWithManualConflictResolution(
public void OnSavedGameConflict(IConflictResolver resolver, ISavedGameMetadata .....) And this OnSavedGameConflict method gets called about every seven seconds and the final OnSavedGameOpenedForRead method never gets called. So the following happens inside the C# plugin code.
Now I could guess that it's not very clever to always return the original meta but that's exactly what OpenWithAutomaticConflictResolution with the option UseOriginal does. This method internally calls the InternalManualOpen method. The only difference is, that it sets the prefatchDataOnConflict parameter to false. |
|
I'm having this issue too. As I traced, the plugin resolved the conflict and tried to reopen saved file, but there is still conflict. It seems that the conflict cannot be resolved. |
|
Btw. The savegame gets loaded after several minutes and we talk about like 10 or 15 minutes. Here's another user (that actually doesn't use the Unity SDK but I guess it's not the SDKs fault): http://stackoverflow.com/questions/37467990/play-games-snapshot-conflict-resolution-gives-conflict |
|
Has anyone made any progress on this? Just wondering which version of the plugin everyone is running to see if this is something that might be related to a specific version. We are currently on 0.9.27, and in the progress of trying to upgrade to latest. The 0.9.34 'current build' unitypackage we downloaded from github was always corrupt, so we had to clone the repo then open the package from there. Once we got the package opening, we ran into this problem, so we are trying to upgrade android sdk as suggested there and see how that goes. |
|
@claywilkinson any chance you could point us in the right direction? Our users are extremely upset that they are unable to play our game and we are feeling pretty stuck :( |
|
@MobileMonsters When the save is finally loaded after 10-15 minutes, does google give you a successful status? Also when opening the metadata again after that point, does it go back into the loop or work from that point onwards? |
|
We have experienced the very same issue. Conflicts out of nowhere, resolution taking more than half an hour only to get STATUS_SNAPSHOT_CONTENTS_UNAVAILABLE. After restarting the game -- same story. Unfortunately, clearing Google Play Services data does not fix this permanently, so we are now going to pursue other cloud save options. |
|
@gwiazdorrr I feel your pain :( Just wanted to confirm that clearing Google Play Services data does not permanently fix the issue for us either, it just gets past the current loop it gets stuck in, and after that there is a chance for it to happen again. Reinstalling our game also temporarily fixes this problem, but not clearing our app data, so we know it's not something our app is holding on to. It's almost as if Google Play Services is identifying our app by an installation id or something. |
|
@miracle7 I don't have an answer to these questions since we don't have this behaviour on our own but our customers have. Has anybody an idea of how this behaviour could be reproduced? |
|
In my case, it seems that it happen just after update apk. And below log is recorded when trying to resolve. It seems that google play games has uid problem. 07-16 21:53:25.606 800 3829 W AppOps : Bad call: specified package com.google.android.play.games under uid 10193 but it is really 10060 |
|
@zelon, @claywilkinson said in this thread that that issue is supposedly not a problem. @MobileMonsters the closest we have come to reproducing it our end is by having two devices running the game simultaneously and continually opening the metadata, modifying it and saving it on both devices. Most of the time the conflicts appear and are resolved as you would expect, but eventually we get stuck in the described conflict loop on one of the devices after we attempt a resolution. There doesn't appear to be any specific steps leading up to this that causes the loop, and looking at the reviews on the google play store it happens across all android versions and devices too, although we usually see it on our Galaxy s6 edge here when we can get it to occur. |
|
@miracle7 We have not found a solution yet and are wondering were the problem is... Google servers? Google play games service? Play Games Plugin for Unity? |
|
I have been in contact with someone at google, and they recommended that I "experiment with altering the device's clock to a future date, saving a game, and then setting the clock back" This is what happened when I tried to save in the future, then return to regular time:
I then get stuck in the following cycle. For the sake of simplicity and ability to reproduce I always resolve using save B, and when saving upload save B, even if the server gives me save A back. I want A to disappear when I do this.
The first time I did this I encountered the looping problem at step 6, and the moment the phones time matched up with the time I jumped forward to, Google Play Services 'stopped working' and I saw this in the logs: The next time I tried to open the metadata, I got the same conflict that it was stuck on, but this time it was resolved successfully and I was able to save and load as per usual. I am not sure whether this is exactly the same problem as we are having, since a lot of our users (maybe 10-15% based on reviews) are experiencing getting stuck in this conflict loop, and the saving in the future thing should be pretty rare as far as I can tell. That being said, this is the closest we have come to reproducing it, would be interested to know how this correlates with the problems others are experiencing. |
|
@claywilkinson It has been almost a month since I opened this issue and multiple people are having their live apps devastated by this bug, we are getting totally swamped with bad reviews and angry support tickets so was wondering whether you have had a chance to take a look at this thread yet? |
|
We finally decided to develop our own solution. It's pretty much fact that We'll use the Google sign-in as identification still and the user will have For the time being we developed a workaround. Once we recognize the loop So at least they can play although it's not making them very happy. Am 22.07.2016 02:08 schrieb "Roman Maksymyschyn" notifications@github.com:
|
|
@MobileMonsters We just had a discussion yesterday in our studio with a very similar resolution, except we will be opting to just disable cloud save entirely rather than wait until they get stuck in a loop or encounter single device conflicts. We will likely just run our own server/system in future to handle syncing saves between devices, using either Facebook or GPG as the unique identifier. Hopefully Google are able to help us resolve this before it gets to that point, but we are starting to lose hope as well and looking into damage control / alternatives. |
|
We have been facing this issue for weeks now and I would like to add some more information on this subject. We have released our Skateboard Party 3 game on June 21st to the Google Play Store, and back then, this issue did not happen. We downloaded our game today and tested it and we could reproduce this issue 100%. This tells us that this is probably a Google Play Services server issue. So, since you've reported this issue 25 days ago, I would guess something happened between June 21st and June 28th that broke on the servers. I will also add that when we have the "looping state" and leave it, the Google Play Services process crashes on our devices. These are the logs when it's looping:
|
|
I have no more info to add to this problem, just wanted to say it's happening for our game as well. This seems like a serious issue that is affecting a lot of games, I really hope this will be fixed soon. |
|
Ok, now how do we get attention of some Google engineers so these problems get solved or so we get any information about what's going on? |
|
I've been fighting with this problem for a whole week and there seems to be no way to even workaround it. We really need some support from the server side :/ |
|
We lost 20% of our DAU since this started ... that correlates with the amount of people that use the Google Games sign in. And its starting to costs us the same amount in revenues! |
|
I open the file again every time. |
|
Thanks - the quick responses help! |
|
Same here. Reopening the file every time. |
|
I just realized this issue has been here for like a month O_O. Should I even expect it to be solved, or switch to another backend completely. |
|
For reference, In my case Nexus 5 device shows stuck in conflict loop problem frequently but not Galaxy S6. I've checked over several games using Saved Games service which already launched in Google Play. I am surprised that almost all games got the same issue and it is not solved yet almost two months. |
|
hi/ Can uoy suggest a correct fix this bug too. We use cloud synch in our app and face this bug too. We make a desigion to turn synch off for now, but we'll like to keep this option for users that needed cloud |
|
So, we've implemented our own solution for saving and syncing files that we currently use for saving the players' progress). The only thing we now need is to retrieve the ServerAuthCode on the client and send it to our server. The server identifies to user with Googles' OAuth calls etc. But it sometimes happen that we get an error when retrieving this code on the client:
Are you aware of this issue? Is there a current workaround or something that I could do wrong like requesting an auth code too often e.g.? |
|
MobileMonsters can you tell me what method you're using to save and sync files, because I am at the point where I am resorting to saving all player data as encrypted data on the player's phone (which is really unsafe and open to hacking / cheating) |
|
@MobileMonsters - You should not need to call GetServerAuthCode too often (How often are you calling it?). Once the server has exchanged the code for an access token, you should have a refresh token as well which is used by the server to keep a valid token for that user. |
|
I signed up to GitHub for the explicit purpose of commenting on this issue. I too am facing the issue and I don't even use this plugin I use a different plugin that wraps the Google Play APIs. The issue is exactly as mentioned, when attempting to resolve a conflict it gets stuck in a loop which either crashes the app or ends after a really long period of time both of which are unacceptable for production behavior. As it stands, everything else is complete and I'm just stuck sitting on my hands until this gets fixed. Glad to hear the team is working @claywilkinson . |
|
Hi @claywilkinson, any updates on this? |
|
Hey, Is it common behavior from Google to have errors such as this one in production? I cannot believe, it has been over 2 months and the issues with saved games still are not fixed. These issues are the only only reason that keeps me from publishing my game. I am also getting afraid of publishing using Google Play Game Services in case something similar happens after the publication. @claywilkinson Any comments? |
|
I think @claywilkinson has abandoned this issue, and has decided to just ignore all 24 of us, because him and his team can't solve the problem. I would just either use another backend like Gamesparks, Playfab, or Photon, or some other solution, because I don't think this will be solved anytime soon, and they are definitely a lot more reliable |
|
@claywilkinson : starting to getting pissed off, like the others. Unlike @TuuttitaR, for me the app is already published. When discovered, that kind of thing should be fixed in a matter of days, not weeks or months! And yeah @TuuttitaR, it's common for Google to ignore these things, just have a look here for example: https://code.google.com/p/android/issues/detail?id=197287 |
|
I'm receiving more and more user reports saying the sync is not working for them anymore. Can we please get an update @claywilkinson? |
|
@claywilkinson : Are the issues with saved games going to get fixed or not? If they are, when is that going to happen? Can we please get a straight answer or update? |
|
Here is what I recently was able to track down: There was a bug in the play services app (not the library) that caused the old data to sometimes be incorrectly returned. Then, having multiple commits to update that data could cause the infinite loop of conflict resolution. Some analysis of games (including the sample apps) could also have overlapping open calls to the same file, which also can cause the infinite conflict loop. Fixes:
Thanks again for your patience and persistence. |
|
@claywilkinson Regarding your two points marked as 1, are those two separated fixes? Can we expect the first fix sooner? |
|
@claywilkinson So for every user having this problem, they will continue to experience it until "sometime in Q4"? Tell me it's a joke, please.... |
|
@felipeota - Yes, the first fix is rolling out now. Overlapping commits across devices works as it should and create 1 conflict per commit. The problem happens when the same version of a file has local commits against it. Opens are technically OK, it is the commit that causes the problem. |
|
We've got the same issue. (Our game is quite big, over 10M installs from Google Play.) So, the solution is to wait until users update their Play Game Services application, isn't it? Or we need to release new build with updated version of Unity plugin? Any ETA? |
|
Joining the crowd, Limbo is also experiencing this issue, using java and BaseGameUtils lib. Our code is pretty much like the examples code - up to 3 recursive attempts to resolve the issue, if either is successful we merge the data manually and try to save it into the resolved snapshot. Often getting a conflict response at that point. The only difference is that we open the two snapshots and read them fully before calling resolveConflict and the later is done in a task. We cannot repro, this info is based on user logs. @claywilkinson Can you confirm that on a device already experiencing the problem either clearing cache or data on the Google Play Services or Google Play Games apps will resolve the problem? |
|
Also still experiencing this issue. Google Play Games app hasn't been updated since 18th July so I guess fix 1 has not been released. |
|
OP of aforementioned http://stackoverflow.com/questions/37467990/play-games-snapshot-conflict-resolution-gives-conflict joining in for updates. Also still experiencing the issue. |
|
@claywilkinson, still got some users encountering this problem. Is it supposed to be totally fixed? |
|
Also still getting this issue. If I commit multiple snapshot saves while disconnected from the internet on device 1, then submit a save on device 2 which is connected to the internet, then come back to device 1 and connect to the internet and attempt to open a snapshot I get this conflict loop issue every time. @claywilkinson Which example project should be followed to prevent this issue from occurring? Thanks. Update: After some further searching, I'm GUESSING you need to use SnapshotCoordinator Class. According to the class:
SnapshotCoordinator Class: https://github.com/playgameservices/android-basic-samples/blob/master/BasicSamples/libraries/BaseGameUtils/src/main/java/com/google/example/games/basegameutils/SnapshotCoordinator.java Example That Leverages it: |
|
I'm getting an InternalError from savedGameClient.OpenWithAutomaticConflictResolution continusouly. It used to work fine until I deleted the data from google drive (manage apps tab). I'm not sure if this is related but it doesn't seem to have a real reason behind it. |
We are having a strange issue where a serverside conflict is always returned when trying to open the metadata, no matter how many times we resolve it.
It seems to be local to the device as other devices still work as expected when this starts happening.
Cloud save works as expected again if we clear the google play services app data (not just the cache).
We are passing the 'ReadNetworkOnly' parameter to the open meta data function, but despite this google play games appears to be doing something offline.
In addition to this strange serverside conflict loop it gets stuck in, if the device has no internet connection and tries to open the metadata, instead of coming back with an error code, it waits a long time before returning the success code and behaving as if it is connected.
Can anyone think of anything I could possibly be doing to cause this to happen? We can not get a reliable repro for this issue and it is causing a lot of problems for our users.
The text was updated successfully, but these errors were encountered: