I am evaluating the new dot net core 7 RC1 along with syncfusion blazor, It throws the following exception when I am using Grid.
[2022-09-19T13:58:54.160Z] Error: System.InvalidOperationException: The converter specified on 'Syncfusion.Blazor.DataManager.Json' is not compatible with the type 'System.Collections.Generic.IEnumerable`1[System.Object]'.
at System.Text.Json.ThrowHelper.ThrowInvalidOperationException_SerializationConverterOnAttributeNotCompatible(Type classTypeAttributeIsOn, MemberInfo memberInfo, Type typeToConvert)
at System.Text.Json.Serialization.Metadata.DefaultJsonTypeInfoResolver.GetConverterFromAttribute(JsonConverterAttribute converterAttribute, Type typeToConvert, MemberInfo memberInfo, JsonSerializerOptions options)
at System.Text.Json.Serialization.Metadata.ReflectionJsonTypeInfo`1.CreateProperty(Type typeToConvert, MemberInfo memberInfo, JsonSerializerOptions options, Boolean shouldCheckForRequiredKeyword)
at System.Text.Json.Serialization.Metadata.ReflectionJsonTypeInfo`1.AddPropertiesAndParametersUsingReflection()
at System.Text.Json.Serialization.Metadata.ReflectionJsonTypeInfo`1..ctor(JsonConverter converter, JsonSerializerOptions options)
at System.Text.Json.Serialization.JsonConverter`1.CreateReflectionJsonTypeInfo(JsonSerializerOptions options)
at System.Text.Json.Serialization.Metadata.DefaultJsonTypeInfoResolver.CreateJsonTypeInfo(Type type, JsonSerializerOptions options)
at System.Text.Json.Serialization.Metadata.DefaultJsonTypeInfoResolver.GetTypeInfo(Type type, JsonSerializerOptions options)
at System.Text.Json.JsonSerializerOptions.GetTypeInfoNoCaching(Type type)
at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
at System.Text.Json.JsonSerializerOptions.GetTypeInfoInternal(Type type, Boolean ensureConfigured, Boolean resolveIfMutable)
at System.Text.Json.Serialization.Metadata.JsonPropertyInfo.Configure()
at System.Text.Json.Serialization.Metadata.JsonTypeInfo.InitializePropertyCache()
at System.Text.Json.Serialization.Metadata.JsonTypeInfo.Configure()
at System.Text.Json.Serialization.Metadata.JsonTypeInfo.<EnsureConfigured>g__ConfigureLocked|138_0()
at System.Text.Json.JsonSerializerOptions.GetTypeInfoInternal(Type type, Boolean ensureConfigured, Boolean resolveIfMutable)
at System.Text.Json.Serialization.JsonConverter.ResolvePolymorphicConverter(Object value, JsonTypeInfo jsonTypeInfo, JsonSerializerOptions options, WriteStack& state)
at System.Text.Json.Serialization.JsonConverter`1.TryWrite(Utf8JsonWriter writer, T& value, JsonSerializerOptions options, WriteStack& state)
at System.Text.Json.Serialization.Converters.DictionaryDefaultConverter`3.OnWriteResume(Utf8JsonWriter writer, TDictionary value, JsonSerializerOptions options, WriteStack& state)
at System.Text.Json.Serialization.JsonDictionaryConverter`3.OnTryWrite(Utf8JsonWriter writer, TDictionary dictionary, JsonSerializerOptions options, WriteStack& state)
at System.Text.Json.Serialization.JsonConverter`1.TryWrite(Utf8JsonWriter writer, T& value, JsonSerializerOptions options, WriteStack& state)
at System.Text.Json.Serialization.JsonConverter`1.WriteCore(Utf8JsonWriter writer, T& value, JsonSerializerOptions options, WriteStack& state)
at System.Text.Json.JsonSerializer.WriteCore[TValue](Utf8JsonWriter writer, TValue& value, JsonTypeInfo`1 jsonTypeInfo)
at System.Text.Json.JsonSerializer.WriteString[TValue](TValue& value, JsonTypeInfo`1 jsonTypeInfo)
at System.Text.Json.JsonSerializer.Serialize[TValue](TValue value, JsonSerializerOptions options)
at Syncfusion.Blazor.Grids.SfGrid`1.SerializeModel(SfGrid`1 comp)
at Syncfusion.Blazor.Grids.SfGrid`1.OnAfterRenderAsync(Boolean firstRender)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask(Task taskToHandle, ComponentState owningComponentState)
Hi Jawaid,
Greetings from Syncfusion support.
We have analyzed your query and prepared sample based on your requirement using SfDataManager in .Net 7 version. But we’re unable to replicate the mentioned issue at our end. Kindly refer the attached sample and reproduce the reported issue in our provided sample. It’ll be more helpful for us to validate the query and provide the solution as early as possible.
Please get back to if you have any further queries.
Regards,
Sarveswaran PK
Hi, I also get this exception.
I tried the attached sample and it gives the same exception.
Only change was nuget package upgrade to 7.0.0-rc.1.22427.2
I am sharing the sample code that I developed in Dot Net Core 7 RC1. I am just using a sample list binding with grid. still I am facing same issue.
https://github.com/jawaidakhter/GridDemoApp2.git
Hey! Just wanted to report a +1 on this.
Should have thought to downgrade the SDK. Thanks!
Hi Jawaid,
Greetings from Syncfusion support.
We have analyzed your query and we would like to inform you that currently our Syncfusion components have only support for .NET6 version only. Hence the reported issue occur in while creating the application in .NET7. Reported issue will be resolved after upgrading our component to .NET 7.
Until then we appreciate your patience.
Regards,
Sarveswaran PK
Hi Pal,
Sorry for the inconvenience caused .
Recently we gave support to all our Components for compatible with .NET 7 Preview versions. But we have problems with serialization processes. Currently, we have checking with RC versions and need some more time to validate this. We update the further details two business days. since ensuring process take time to confirmation.
Kindly get back to us if you have any further queries
Regards,
Sarveswaran PK
Hi Jawaid,
We are glad to announce that, we have included fix for the serialization issue in our weekly patch release (20.3.0.49). So please upgrade to our latest version of Syncfusion NuGet package to resolve the reported issue. Please find the Nuget package for latest fixes and features from below.
Nuget : https://www.nuget.org/packages/Syncfusion.Blazor.Grid
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.
Regards,
Sarveswaran PK
Hi Jawaid,
Thanks for the update.
We are currently Validating the reported query at our end, and we will update the further details within two business days. Until then we appreciate your patience.
Regards,
Sarveswaran PK