Closed tim-rue closed 5 months ago
I'll take a look at them now. These shouldn't have been affected at all. While I look into this, can you send me an example of the yaml your using?
Ok, found the issues. There was 2 problems, one with internal constructors. That will be fixed. The other is with the ensureroundtrip. There was an option that was supposed to be set so it would do something, but, it was never set in the typeassigningeventemitter. That was now correctly being set which is why you are seeing the behavior. Since that is different from what was expected I've removed the relevant code so that is back to how it was.
I've also adjusted the tests to include the 4 different types of constructors, internal, private, protected and public.
I'll get a new version out today hopefuly.
A fix for this issue has been released in version 15.1.1.
All our tests are passing now and the behavior seems to be back to how it was. Thanks a lot!
Describe the bug When trying out the new release I encountered two problems with my project.
EnsureRoundtrip()
does not work if I use a tag mapping for each class, but it worked before. Why do I need a tag mapping if the type can be resolved through the object graph?EnablePrivateConstructors()
used to enable protected constructors as well. Now I have to use private or public constructorsTo Reproduce
This works in 13.7.1, but not in 15.1.0:
.WithTagMapping(new TagName("!Test"), typeof(TestClass))
does fix the problem, but that doesn't help for existing yaml files.These are very breaking changes and make backwards compability impossible. For each class I serialize, I'd have to add a type mapping and make the constructor private instead of protected. Is there any solution I don't know about?