Search Issue Tracker

Active

Under Consideration for 1.1.X

Votes

0

Found in [Package]

1.1.1

Issue ID

UGSB-26

Regression

No

[General] Player throws error when serializing Services Economy config

Package: Cloud Services Apis

-

Reproduction steps:
1. Open the attached “IN-88563_bugrepro” project
2. Build the project for Linux Server
3. Launch the Linux server

Expected results: The server does not throw any errors related to the serialization of service configs
Actual results: The server throws serialization errors

Reproduced with: 1.1.0 (6000.0.18f1)

Error:

{noformat}Failed to deserialize `{"initial":0,"max":0,"created":{"date":"2024-10-29T09:44:26Z"},"customData":null,"id":"BRICKS_TOKENS","modified":{"date":"2024-10-29T09:44:26Z"},"name":"Bricks Tokens","type":"CURRENCY"}` into InventoryItemResource: Newtonsoft.Json.JsonSerializationException: Could not find member 'initial' on object of type 'InventoryItemResource'. Path 'initial', line 1, position 12.
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.ResolvePropertyAndCreatorValues (Newtonsoft.Json.Serialization.JsonObjectContract contract, Newtonsoft.Json.Serialization.JsonProperty containerProperty, {noformat}

To workaround this issue, control the stripping through a link.xml file in your assets folder. Add an entry to preserve the assembly in question:

{noformat}<linker>
<assembly fullname="Unity.Services.Apis" preserve="all">
</assembly>
</linker>{noformat}

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.