Microsoft Azure PlayFab logo
    • Multiplayer
    • LiveOps
    • Data & Analytics
    • Add-ons
    • For Any Role

      • Engineer
      • Designer
      • Executive
      • Marketer
    • For Any Stage

      • Build
      • Improve
      • Grow
    • For Any Size

      • Solo
      • Indie
      • AAA
  • Runs on PlayFab
  • Pricing
    • Blog
    • Forums
    • Contact us
  • Sign up
  • Sign in
  • Ask a question
  • Spaces
    • PlayStream
    • Feature Requests
    • Add-on Marketplace
    • Bugs
    • API and SDK Questions
    • General Discussion
    • LiveOps
    • Topics
    • Questions
    • Articles
    • Ideas
    • Users
    • Badges
  • Home /
  • Bugs /
avatar image
Question by Victor Ocariz · May 31, 2021 at 01:29 AM · CloudScript

CloudScript executed from Player dashboard returns unreadable response

Hello there!

So first some context. Every time that we are working on a new handler for the CloudScript, we test it first from the Player dashboard, so we can quickly test the revision without deploying it to "LIVE" and then catch any issues to be polished.

But from a while now, all the data in the responses and the logs is looking like this:

{
    "FunctionResult": [
        [
            []
        ],
        [
            []
        ],
        [
            [
                [
                    []
                ],
                [
                    [
                        [
                            [
                                [
                                    [
                                        []
                                    ],
                                    [
                                        []
                                    ],
                                    [
                                        [
                                            [
                                                []
                                            ]
                                        ]
                                    ]
                                ]
                            ]
                        ]
                    ]
                ],
                [
                    []
                ],
                [
                    [
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            [
                                [
                                    [
                                        []
                                    ]
                                ]
                            ]
                        ]
                    ]
                ]
            ]
        ]
    ],
    "Logs": [
        {
            "Level": "Error",
            "Message": "PlayFab API request error",
            "Data": [
                [
                    []
                ],
                [
                    [
                        [
                            [
                                [
                                    [
                                        []
                                    ],
                                    [
                                        []
                                    ],
                                    [
                                        [
                                            [
                                                []
                                            ]
                                        ]
                                    ]
                                ]
                            ]
                        ]
                    ]
                ],
                [
                    []
                ],
                [
                    [
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            []
                        ],
                        [
                            [
                                [
                                    [
                                        []
                                    ]
                                ]
                            ]
                        ]
                    ]
                ]
            ]
        }
    ],
    "ExecutionTimeSeconds": 0.0344686,
    "MemoryConsumedBytes": 221888,
    "APIRequestsIssued": 1,
    "HttpRequestsIssued": 0,
    "Error": null
}

The execution is doing fine, but I guess this could be some problem with the dashboard response encoder or how the dashboard shows the data to us.


The "ExecuteCloudScriptRequest" from the Unity client the response is just working as expected, no weird brackets as response. We can always test the revisions building a request from Unity, but this is more time consuming and we'd love to have the dashboard working smoothly as it used to do before!

Let me know if we can do anything to help and track this issue.

Comment

People who like this

0 Show 0
10 |1200 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
Best Answer

Answer by Sarah Zhang · May 31, 2021 at 09:35 AM

After testing, we found the CloudScript returns the Json Object as the empty array on the Players/CloudScript page. It should be a Game Manager display issue. Did your Players/CloudScript page can display the correct JSON Object before?

Currently, the possible workaround is to use the external testing tool -- Postman to test the API ExecuteCloudScript. Please refer to this document -- Quickstart PlayFab REST API collection for Postman - PlayFab | Microsoft Docs to learn about how to use the Postman to test the PlayFab API. Since the Players/CloudScript page can show the correct JSON string, you can also try to use the JSON.stringify method to convert your result to string, so that the Players/CloudScript page can display it.

Comment

People who like this

0 Show 2 · Share
10 |1200 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Victor Ocariz · May 31, 2021 at 10:09 AM 0
Share

Hi Sarah, thank you for your answer.

Yes, we were able to display the correct JSON Object before. Some weeks ago.

And also we've already tried to use the JSON.stringify() method to see if the object would be displayed correctly but still the same result.

I'll check the Postman tool for testing meanwhile.

Thank you again!

avatar image Sarah Zhang Victor Ocariz · Jun 01, 2021 at 08:49 AM 0
Share

Thanks for the report, we will inform our team to investigate this [Game Manager] display issue.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Navigation

Spaces
  • General Discussion
  • API and SDK Questions
  • Feature Requests
  • PlayStream
  • Bugs
  • Add-on Marketplace
  • LiveOps
  • Follow this Question

    Answers Answers and Comments

    2 People are following this question.

    avatar image avatar image

    Related Questions

    Where did the Upload New Revision button go? 1 Answer

    GetFriendList return empty Tags array 1 Answer

    Unable to locally debug playstream event trigerred cloudscript (azure functions) 1 Answer

    Cloud script execute more once 1 Answer

    GetStoreItems throws JavascriptException in CloudScript 4 Answers

    PlayFab

    • Multiplayer
    • LiveOps
    • Data & Analytics
    • Runs on PlayFab
    • Pricing

    Solutions

    • For Any Role

      • Engineer
      • Designer
      • Executive
      • Marketer
    • For Any Stage

      • Build
      • Improve
      • Grow
    • For Any Size

      • Solo
      • Indie
      • AAA

    Engineers

    • Documentation
    • Quickstarts
    • API Reference
    • SDKs
    • Usage Limits

    Resources

    • Forums
    • Contact us
    • Blog
    • Service Health
    • Terms of Service
    • Attribution

    Follow us

    • Facebook
    • Twitter
    • LinkedIn
    • YouTube
    • Sitemap
    • Contact Microsoft
    • Privacy & cookies
    • Terms of use
    • Trademarks
    • Safety & eco
    • About our ads
    • © Microsoft 2020
    • Anonymous
    • Sign in
    • Create
    • Ask a question
    • Create an article
    • Post an idea
    • Spaces
    • PlayStream
    • Feature Requests
    • Add-on Marketplace
    • Bugs
    • API and SDK Questions
    • General Discussion
    • LiveOps
    • Explore
    • Topics
    • Questions
    • Articles
    • Ideas
    • Users
    • Badges