We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Consider the following structure
public class Person { public string Name { get; set; } public Dictionary<string, object> Metadata { get; set; } }
The encoder doesn't seem to have an issue and serializes the dictionary correctly; here's the encoded value ToString().
ToString()
ObjectV(name: StringV(Japanfy),metadata: ObjectV(comm.status: StringV(connected),comm.satellites: LongV(8)))
However, the decoder doesn't behave well with this and doesn't decode the values of the dictionary. It just creates an empty object for each.
{"Name":"Japanfy","Metadata":{"comm.status":{},"comm.satellites":{}}}
The text was updated successfully, but these errors were encountered:
As per discussed in the Slack channel...
What object should we use to decode when we find an object? @marrony
What object should we use to decode when we find an object?
If the value is a StringV, then it should be a string, for example.
When we are encoding, what matters is the actual object type. So, when we are decoding, shouldn't we consider using the value type?
Sorry, something went wrong.
No branches or pull requests
Consider the following structure
The encoder doesn't seem to have an issue and serializes the dictionary correctly; here's the encoded value
ToString()
.However, the decoder doesn't behave well with this and doesn't decode the values of the dictionary. It just creates an empty object for each.
The text was updated successfully, but these errors were encountered: