question

longtoothgames avatar image
longtoothgames asked

master_player_account not found in namespace error

I have an azure function i currently run manually from playfab (below code) via execture task on the segment of all players. The function sets a statistic value and some user data. The function seems to run fine and updates the all of the players, however, I get the same error twice (apparently for two different accounts).

Here are the errors: 2023 - 03 - 18T19: 49:34Z[Warning] User not found 1 - 641615cd - 0c27c0257f2be4d73dc7c655 2023 - 03 - 18T19: 49:34Z[Warning] master_player_account 16822171537723680430 not found in namespace 6DE4A01802FE9180 1-641615cd-4ec7dde077785a546315d609 2023-03-18T19:49:34Z[Warning] User not found 1-641615ce-4ea1c44057128b3d3f14b483 2023-03-18T19:49:35Z[Warning] master_player_account 13290559924692377474 not found in namespace 6DE4A01802FE9180 1-641615ce-58fb2d6c50b2d337344026f5

I was thinking that somehow there is a master account being accessed that does not have an account on the title, but I'm not sure. The account numbers its listing are 20 digit and so far as I know the playfab ids are 16 characters. Any help would be much appreciated.

         [FunctionName("ResetPlayerPuzzleData")]
         public static async Task ResetPlayerPuzzleData(
             [HttpTrigger(AuthorizationLevel.Anonymous, "get", "post", Route = null)] HttpRequest req,
             ILogger log)
         {
             var context = JsonConvert.DeserializeObject<PlayerPlayStreamFunctionExecutionContext>(await req.ReadAsStringAsync());
    
             var puzzleScoreUpdate = new StatisticUpdate
             {
                 StatisticName = PlayfabServerKeys.DailyPuzzle,
                 Value = 0
             };
    
             var updatePuzzleScoreReq = new UpdatePlayerStatisticsRequest
             {
                 ForceUpdate = true,
                 PlayFabId = context.PlayerProfile.PlayerId,
                 Statistics = new List<StatisticUpdate> { puzzleScoreUpdate }
             };
    
             PlayFabResult<UpdatePlayerStatisticsResult> puzzleScoreResult = await PlayFabServerAPI.UpdatePlayerStatisticsAsync(updatePuzzleScoreReq);
             if (puzzleScoreResult.Error != null)
                 log.LogWarning(puzzleScoreResult.Error.GenerateErrorReport());
    
    
             var updateDataDict = new Dictionary<string, string>
             {
                 { PlayfabServerKeys.PuzzleWordPlayed, ""}
             };
    
             var wordPlayedRequest = new UpdateUserDataRequest
             {
                 Data = updateDataDict,
                 PlayFabId = context.PlayerProfile.PlayerId,
             };
    
             PlayFabResult<UpdateUserDataResult> updateWordResult = await PlayFabServerAPI.UpdateUserDataAsync(wordPlayedRequest);
             if (updateWordResult.Error != null)
                 log.LogWarning(updateWordResult.Error.GenerateErrorReport());
         }
apisAccount Management
7 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Simon Cui avatar image Simon Cui commented ·

The issue may be caused by UpdateUserDataRequest. Could you append a log message to get the PlayFab Id in your azure function? When you have that 2 specific PlayFabIds, you can check them in your title. Or you can provide those 2 PlayFabIds and TitleId for us to investigate.

0 Likes 0 ·
longtoothgames avatar image longtoothgames Simon Cui commented ·

Added the id log. Checked for the player accounts using the ids from the game manager and neither one showed up. I recall during early development having some issue with deleting a player account without unlinking custom account ids, but I'm not sure if this is related.

Does the scheduled task "player segment" call the function for each title player account or each master player account? I would think is should be title, but if the latter, I could see where the problem lies.

Also, in the game manager players tab, it says i have 12 players, but only shows 10. However, if I look at the leaderboards, it shows all 12, including the below two player ids. If I click on them, it takes me to a blank page, unlike the other 10.

ids are:

B8718DD5C954DF82

E9745BE2C8B4E6AE

5673-image.png

5674-image.png

0 Likes 0 ·
image.png (72.9 KiB)
image.png (30.5 KiB)
Simon Cui avatar image Simon Cui longtoothgames commented ·

Does the scheduled task "player segment" call the function for each title player account or each master player account?

Could you please clarify more about “call the function”? The account type (title_player_account or master_player_account) depends on which API the function is using and what the request field it has.

For those two “deleted” accounts, you can use Account Management - Get User Account Info - REST API (PlayFab Server) | Microsoft Learn to check and see what the result is.

Please provide your titleId for us if you need further help. Thank you.

0 Likes 0 ·
Show more comments

1 Answer

·
Simon Cui avatar image
Simon Cui answered

Player deletion is not an instant action. It takes a while to clean it all up. Usually, it takes less than a few hours. In rare cases, we've seen it take days. You can refer to this similar case: https://community.playfab.com/questions/29646/delete-master-accountdeleting-master-account.html

The total players count showing on the Game Manager maybe delay and different from the actual player count. This is unavoidable when accounts are in deletion queue. There is some delay in segment auto-update as well. When a player is deleted, the segment does not update immediately, causing the schedule task issue of those 2 deleted players. Please understand that the segment cannot be updated all the time, which is by design.

10 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

longtoothgames avatar image longtoothgames commented ·

Thank you, I realize updates take a while, however, the two original account numbers that are causing the issue have been gone for at least weeks, more than likely months, not days or hours. The most recent account I created and then deleted for testing I understand it still being around due to the update delay, but not the other two.

So at what point is something considered wrong with account deletion? If the number stays around for a week? month? year? And can you guys manually remove them?

Also, the link you posted is broken.

0 Likes 0 ·
Simon Cui avatar image Simon Cui longtoothgames commented ·

Sorry for the broken link, there was a dot at the end of the link and I have removed it. After researching, the main issue of your case is caused by segment update delay. Those accounts have been deleted but their profile information still exist in the segment. Do you have the access to the support ticket? If so, you can report this issue by submitting a ticket.

0 Likes 0 ·
longtoothgames avatar image longtoothgames Simon Cui commented ·

I do not have access to support tickets at this time. To my understanding, that requires a standard account, not pay as you go correct?

0 Likes 0 ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.