You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running the deserialization example from the README when published for Linux64 (in WSL) a get following exception:
Exception during deserialization
at YamlDotNet.Serialization.ValueDeserializers.NodeValueDeserializer.DeserializeValue(IParser, Type, SerializerState, IValueDeserializer)
at YamlDotNet.Serialization.ValueDeserializers.AliasValueDeserializer.DeserializeValue(IParser, Type, SerializerState, IValueDeserializer)
at YamlDotNet.Serialization.Deserializer.Deserialize(IParser, Type)
at YamlDotNet.Serialization.Deserializer.Deserialize[T](IParser)
at YamlDotNet.Serialization.Deserializer.Deserialize[T](TextReader)
at YamlDotNet.Serialization.Deserializer.Deserialize[T](String)
Unhandled exception. (Line: 2, Col: 1, Idx: 2) - (Line: 2, Col: 1, Idx: 2): Exception during deserialization
It works on Windows.
To Reproduce
Try to add the steps needed to reproduce the problem. Feel free to open a pull request with a failing test if that makes sense. Otherwise, at least provide some code and / or YAML that reproduce the issue.
staticvoidTestYaml(){varyml=@"name: George Washingtonage: 89height_in_inches: 5.75addresses: home: street: 400 Mockingbird Lane city: Louaryland state: Hawidaho zip: 99970";try{vardeserializer=newDeserializerBuilder().WithNamingConvention(UnderscoredNamingConvention.Instance)// see height_in_inches in sample yml .Build();//yml contains a string containing your YAMLvarp=deserializer.Deserialize<Person>(yml);// Exception herevarh=p.Addresses["home"];System.Console.WriteLine($"{p.Name} is {p.Age} years old and lives at {h.Street} in {h.City}, {h.State}.");// Output:// George Washington is 89 years old and lives at 400 Mockingbird Lane in Louaryland, Hawidaho.}catch(Exceptionex){Console.WriteLine($"{ex.Message}\n{ex.StackTrace}");throw;}}
Then publish for
Then run. (I ran in WSL but I don't see why it shouldn't fail on the real thing).
Thanks
The text was updated successfully, but these errors were encountered:
Because you're doing the produce single file/trimming you'll need to also reference the vecc.yamldotnet.staticanalyzers package and set that up. See #740 and #753.
Describe the bug
When running the deserialization example from the README when published for Linux64 (in WSL) a get following exception:
It works on Windows.
To Reproduce
Try to add the steps needed to reproduce the problem. Feel free to open a pull request with a failing test if that makes sense. Otherwise, at least provide some code and / or YAML that reproduce the issue.
Then publish for
Then run. (I ran in WSL but I don't see why it shouldn't fail on the real thing).
Thanks
The text was updated successfully, but these errors were encountered: