Darren Thomas Lodwick avatar image
Darren Thomas Lodwick asked

"Invalid JSON string" on startup, despite no changes.

I opened my project that was working just fine a week ago, with no changes in the interim, only to get an error whenever I open the Unity project or try to run it. I searched here for people having similar errors, but they all seem to be from over a couple years ago and I didn't really see much in the way of relevant solutions. Just posts with similar titles and unclear solutions.

I see things about encoding being thrown around, but nobody seems to offer a more newbie friendly explanation for the actual fix, which is frustrating.

Here is the error:

PlayFab EditorExtensions: Caught an error:Invalid JSON string

UnityEngine.Debug:LogError (object)

PlayFab.PfEditor.PlayFabEditor:StateUpdateHandler (PlayFab.PfEditor.PlayFabEditor/EdExStates,string,string) (at Assets/PlayFabEditorExtensions/Editor/PlayFabEditor.cs:332)

PlayFab.PfEditor.PlayFabEditor:RaiseStateUpdate (PlayFab.PfEditor.PlayFabEditor/EdExStates,string,string) (at Assets/PlayFabEditorExtensions/Editor/PlayFabEditor.cs:247)

PlayFab.PfEditor.PlayFabEditorHelper:SharedErrorCallback (PlayFab.PfEditor.EditorModels.PlayFabError) (at Assets/PlayFabEditorExtensions/Editor/Scripts/Utils/PlayFabEditorHelper.cs:127)

PlayFab.PfEditor.PlayFabEditorHttp:OnWwwError (System.Action`1,string) (at Assets/PlayFabEditorExtensions/Editor/Scripts/PlayFabEditorSDK/PlayFabEditorHttp.cs:130)

PlayFab.PfEditor.PlayFabEditorHttp/<>c_DisplayClass2_0`2:b_1 (string) (at Assets/PlayFabEditorExtensions/Editor/Scripts/PlayFabEditorSDK/PlayFabEditorHttp.cs:95)

PlayFab.PfEditor.PlayFabEditorHttp/d__7:MoveNext () (at Assets/PlayFabEditorExtensions/Editor/Scripts/PlayFabEditorSDK/PlayFabEditorHttp.cs:177)

PlayFab.PfEditor.EditorCoroutine:Update () (at Assets/PlayFabEditorExtensions/Editor/Scripts/Utils/EditorCoroutine.cs:103)

UnityEditor.EditorApplication:Internal_CallUpdateFunctions ()

I'm running on a Windows machine, with Unity 2020.3.

Player DatawindowsPlayer Inventory
10 |1200

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

1 Answer

Xiao Zha avatar image
Xiao Zha answered

I can't reproduce this issue using Unity 2022.3.4f1 and PlayFabEdEx 2.170.230707. Which version of PlayFabEdEx you are using? You may try to update the PlayFab Editor Extensions to the latest version to see if the issue still exists. Also, the PlayFab Editor Extensions is just used to help you configure the PlayFab environment and is not necessary, you may refer to Installing the PlayFab SDK for Unity - PlayFab | Microsoft Learn to manually configuration PlayFab environment without using Editor Extension.

10 |1200

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

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.