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
and this time, even removing the private keyword (hence allowing a pubic ctor) still results in a serialization issue Cannot create and populate list type NonEmptyList.
Issue relates to #269 but is a little different.
With the code given on #269 making the type public solves the issue but the code sample was a little too simplified.
My real type is as follow:
and this time, even removing the
private
keyword (hence allowing a pubic ctor) still results in a serialization issueCannot create and populate list type NonEmptyList
.This seems to be a known issue for Newtonsoft when implementing
IEnumerable<T>
(see for example https://stackoverflow.com/questions/36926867/deserializing-json-into-a-list-of-objects-cannot-create-and-populate-list-type) but the issue is solved on recent versions (see https://stackoverflow.com/a/36927705/4625433) as long as the type contains a public constructor accepting aIEnumerable<T>
argument which isn't the case for our fsharp types.I haven't dig deeper to understand if there is anything that could be done on your side but I thought that might be better to post it.
The text was updated successfully, but these errors were encountered: