Skip to content
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

"UnityEngine.Assertions.AssertionException: Assertion failure. Value was False" #171

Open
AldeRoberge opened this issue Feb 4, 2024 · 1 comment

Comments

@AldeRoberge
Copy link
Contributor

AssertionException: Assertion failure. Value was False Expected: True — UnityEngine.Assertions.AssertionException: Assertion failure. Value was False Expected: True void UnityEngine.Assertions.Assert.Fail(string message, string userMessage) void UnityEngine.Assertions.Assert.IsTrue(bool condition, string message) x 2 void mixpanel.Value.Merge(Value other) in ./Library/PackageCache/com.mixpanel.unity@f64bde1541/Mixpanel/Value.cs:223 void mixpanel.Controller.DoTrack(string eventName, Value properties) in ./Library/PackageCache/com.mixpanel.unity@f64bde1541/Mixpanel/Controller.cs:346 void mixpanel.Mixpanel.Track(string eventName, Value properties) in ./Library/PackageCache/com.mixpanel.unity@f64bde1541/Mixpanel/MixpanelAPI.cs:275 void Magic.Modules.Analytics.MagicAnalytics.PlayerScoreIncreaseEvent(int score) in Assets/Magic/Modules/Networking/Client/Runtime/Scripts/Analytics/MagicAnalytics.cs:21

This happens when running the following code :

public static void PlayerScoreIncreaseEvent(int score) => Mixpanel.Track(nameof(PlayerScoreIncreaseEvent), score);

Would it be possible to have a better error message? I can't seem to understand why this happens, and I couldn't find in the todcs

Assert.IsTrue(_valueType == ValueTypes.ARRAY || _valueType == ValueTypes.OBJECT);

@AldeRoberge
Copy link
Contributor Author

Still getting this error, it seems like the API wrapper doesn't handle numeric values... We must use the MixPanel.People.Increment and MixPanel.People.Decrement to pass float values

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant