elsa-core icon indicating copy to clipboard operation
elsa-core copied to clipboard

Error when trying to view a workflow instance

Open ShemJM opened this issue 5 months ago • 2 comments

Description

I have been getting this issue across multiple versions of Elsa and for certain workflow definitions, although pretty inconsistent as to why as they don't use the same activities.

I get an error when trying to view the instance, in production the error is NullReferenceException: Arg_NullReferenceException

when running locally it is NullReferenceException: Object reference not set to an instance of an object.

  1. Reproduction Rate: every time

Expected Behavior

View the instance

Actual Behavior

Error is thrown

Screenshots

Image

Environment

  • Elsa Package Version: 3.4.0

Log Output

  Sending HTTP request POST https://localhost:44397/elsa/api/workflow-instances/83def16940ce37f8/journal?*

info: System.Net.Http.HttpClient.IWorkflowInstancesApi.ClientHandler[101] Received HTTP response headers after 50.6ms - 200 info: System.Net.Http.HttpClient.IWorkflowInstancesApi.LogicalHandler[101] End processing HTTP request after 63.1ms - 200 fail: Microsoft.AspNetCore.Components.Web.ErrorBoundary[0] System.NullReferenceException: Object reference not set to an instance of an object. at Elsa.Studio.Workflows.Components.WorkflowInstanceViewer.Components.WorkflowInstanceDetails.GetLastWorkflowActivityExecutionRecordAsync(String workflowInstanceId) at Elsa.Studio.Workflows.Components.WorkflowInstanceViewer.Components.WorkflowInstanceDetails.GetWorkflowActivityExecutionRecordAsync(String workflowInstanceId) at Elsa.Studio.Workflows.Components.WorkflowInstanceViewer.Components.WorkflowInstanceDetails.OnParametersSetAsync() at Microsoft.AspNetCore.Components.ComponentBase.CallStateHasChangedOnAsyncCompletion(Task task) System.NullReferenceException: Object reference not set to an instance of an object. at Elsa.Studio.Workflows.Components.WorkflowInstanceViewer.Components.WorkflowInstanceDetails.GetLastWorkflowActivityExecutionRecordAsync(String workflowInstanceId) at Elsa.Studio.Workflows.Components.WorkflowInstanceViewer.Components.WorkflowInstanceDetails.GetWorkflowActivityExecutionRecordAsync(String workflowInstanceId) at Elsa.Studio.Workflows.Components.WorkflowInstanceViewer.Components.WorkflowInstanceDetails.OnParametersSetAsync() at Microsoft.AspNetCore.Components.ComponentBase.CallStateHasChangedOnAsyncCompletion(Task task)

ShemJM avatar Jun 12 '25 09:06 ShemJM

This should be much better with 3.5.0 (currently in RC)

sfmskywalker avatar Jun 12 '25 17:06 sfmskywalker

This should be much better with 3.5.0 (currently in RC)

I did try to upgrade but due to an issue with the JavaScript feature changes, I am unable to.

ShemJM avatar Jun 13 '25 07:06 ShemJM

@ShemJM Did you find a solution?

henrikx avatar Oct 20 '25 12:10 henrikx

@sfmskywalker I updated to Elsa 3.5.1, but still the same issue. It seems to happen when certain activities are either executing or faulted. If succeeded, I'm having no errors.

henrikx avatar Oct 21 '25 14:10 henrikx

I have done some more debugging, and it seems that for the workflow instance which gets the error, the response to elsa/api/workflow-instances/{id} is missing the workflowState-property. I think this is the root cause of the error, as WorkflowState is never supposed to be null on a WorkflowInstance (at least it being null is not accounted for in GetLastWorkflowActivityExecutionRecordAsync(String workflowInstanceId)-method).

Will try to find out why the backend is not sending that when this particular activity is faulted. It's very strange considering this workflowState is present when a different activity in the same workflow definition was faulted.

henrikx avatar Oct 22 '25 11:10 henrikx

@ShemJM Hopefully this helps:

The real error happens here in the backend:

    private async ValueTask OnLoadAsync(ManagementElsaDbContext managementElsaDbContext, WorkflowInstance? entity, CancellationToken cancellationToken)
    {
        if (entity == null)
            return;

        var data = entity.WorkflowState;
        var json = (string?)managementElsaDbContext.Entry(entity).Property("Data").CurrentValue;
        var compressionAlgorithm = (string?)managementElsaDbContext.Entry(entity).Property("DataCompressionAlgorithm").CurrentValue ?? nameof(None);
        var compressionStrategy = _compressionCodecResolver.Resolve(compressionAlgorithm);

        try
        {
            if (!string.IsNullOrWhiteSpace(json))
            {
                json = await compressionStrategy.DecompressAsync(json, cancellationToken);
                data = _workflowStateSerializer.Deserialize(json);
            }
        }
        catch (Exception exp) // <-- This catch here
        {
            _logger.LogWarning(exp, "Exception while deserializing workflow instance state: {InstanceId}. Reverting to default state", entity.Id);
        }
        entity.WorkflowState = data; // Since deserialization failed, this will be null.
    }

{System.NotSupportedException: Reference metadata is not supported when deserializing constructor parameters. See type 'Workflows.Core.Dto.IdentityObject'. The unsupported member type is located on type 'Workflows.Core.Dto.IdentityObjectType'. Path: $.identity.identityObjects.$values[0].type.$ref | LineNumber: 0 | BytePositionInLine: 198.
 ---> System.NotSupportedException: Reference metadata is not supported when deserializing constructor parameters. See type 'Workflows.Core.Dto.IdentityObject'.
   --- End of inner exception stack trace ---
   at System.Text.Json.ThrowHelper.ThrowNotSupportedException(ReadStack& state, Utf8JsonReader& reader, Exception innerException)
   at System.Text.Json.ThrowHelper.ThrowNotSupportedException_ObjectWithParameterizedCtorRefMetadataNotSupported(ReadOnlySpan`1 propertyName, Utf8JsonReader& reader, ReadStack& state)
   at System.Text.Json.JsonSerializer.TryReadMetadata(JsonConverter converter, JsonTypeInfo jsonTypeInfo, Utf8JsonReader& reader, ReadStack& state)
   at System.Text.Json.Serialization.Converters.ObjectWithParameterizedConstructorConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.Converters.SmallObjectWithParameterizedConstructorConverter`5.TryRead[TArg](ReadStack& state, Utf8JsonReader& reader, JsonParameterInfo jsonParameterInfo, TArg& arg)
   at System.Text.Json.Serialization.Converters.SmallObjectWithParameterizedConstructorConverter`5.ReadAndCacheConstructorArgument(ReadStack& state, Utf8JsonReader& reader, JsonParameterInfo jsonParameterInfo)
   at System.Text.Json.Serialization.Converters.ObjectWithParameterizedConstructorConverter`1.ReadConstructorArgumentsWithContinuation(ReadStack& state, Utf8JsonReader& reader, JsonSerializerOptions options)
   at System.Text.Json.Serialization.Converters.ObjectWithParameterizedConstructorConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.JsonCollectionConverter`2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, T& value, JsonSerializerOptions options, ReadStack& state)
   at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.Deserialize(Utf8JsonReader& reader, ReadStack& state)
   at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.DeserializeAsObject(Utf8JsonReader& reader, ReadStack& state)
   at System.Text.Json.JsonSerializer.ReadFromSpanAsObject(ReadOnlySpan`1 utf8Json, JsonTypeInfo jsonTypeInfo, Nullable`1 actualByteCount)
   at System.Text.Json.JsonSerializer.ReadFromSpanAsObject(ReadOnlySpan`1 json, JsonTypeInfo jsonTypeInfo)
   at System.Text.Json.JsonSerializer.Deserialize(String json, Type returnType, JsonSerializerOptions options)
   at Elsa.Workflows.Serialization.Converters.PolymorphicObjectConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options)
   at Elsa.Workflows.Serialization.Converters.PolymorphicDictionaryConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.JsonCollectionConverter`2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, T& value, JsonSerializerOptions options, ReadStack& state)
   at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.Deserialize(Utf8JsonReader& reader, ReadStack& state)
   at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 utf8Json, JsonTypeInfo`1 jsonTypeInfo, Nullable`1 actualByteCount)
   at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 json, JsonTypeInfo`1 jsonTypeInfo)
   at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, JsonSerializerOptions options)
   at Elsa.Workflows.Serialization.Serializers.JsonWorkflowStateSerializer.Deserialize(String serializedState)
   at Elsa.EntityFrameworkCore.Modules.Management.EFCoreWorkflowInstanceStore.OnLoadAsync(ManagementElsaDbContext managementElsaDbContext, WorkflowInstance entity, CancellationToken cancellationToken)}

So it appears to be an issue with unsupported deserialization of a certain custom type in the activity-data stored in WorkflowInstances.Data in the database.

The type in question:

using System.Text.Json.Serialization;

namespace Workflows.Core.Dto;

public record class IdentityObjectType
{
    public string Value { get; private set; }
    [JsonConstructor]
    protected IdentityObjectType(string value)
    {
        Value = value;
    }
    public static IdentityObjectType Unknown { get; } = new(nameof(Unknown));
}

So it seems that classes or records without a parameterless constructor is absolutely unsupported in Elsa.

@sfmskywalker I think the error should actually be thrown - since an item that's defined as non-nullable being null represents a logical inconsistency that should be surfaced.

henrikx avatar Oct 22 '25 15:10 henrikx

@ShemJM Did you find a solution?

Hi, kind of. I found that when going through the variables and changing it from the deprecated version to workflow instance, then I was able to view the new instances.

Image

ShemJM avatar Oct 24 '25 08:10 ShemJM

@ShemJM That's interesting. Mine was already set to "Workflow Instance" for all variables, so this solution would not do anything for me.

henrikx avatar Oct 24 '25 08:10 henrikx

Same issue here on 3.5.1. When the workflow instance is faulted, it can't be accessed through the studio + API response is the stack trace (I have an HttpEndpoint type of workflow). My variables are also set to "Workflow Instance"

manoelnunesborba avatar Nov 24 '25 15:11 manoelnunesborba

Reproducing

I've modified the example that is given on the docs

 builder.Root = new Sequence
 {
     Activities =
     {
         new HttpEndpoint
         {
             Path = new("/hello-world"),
             CanStartWorkflow = true,
             Authorize = new(false),
             QueryStringData = new(queryStringsVariable)
         },
         new SetVariable
         {
             Variable = messageVariable,
             Value = new(context =>
             {
                 var queryStrings = queryStringsVariable.Get(context)!;
                 var message = queryStrings.TryGetValue("message", out var messageValue) ? messageValue.ToString() : "Hello world of HTTP workflows!";
                 return message;
             })
         },
         new Fault
         {
             Message = new("test")
         },
         new WriteHttpResponse
         {
             Content = new(messageVariable)
         }
     }
 };

And this works, the main difference between this and my custom definition is that mine has a Activity = new Sequence.

So I've added it here

builder.Root = new Sequence
{
    Activities =
    {
        new HttpEndpoint
        {
            Path = new("/hello-world"),
            CanStartWorkflow = true,
            Authorize = new(false),
            QueryStringData = new(queryStringsVariable)
        },
        new SetVariable
        {
            Variable = messageVariable,
            Value = new(context =>
            {
                var queryStrings = queryStringsVariable.Get(context)!;
                var message = queryStrings.TryGetValue("message", out var messageValue) ? messageValue.ToString() : "Hello world of HTTP workflows!";
                return message;
            })
        },
         new SendHttpRequest
         {
             Url = new(new Uri("https://jsonplaceholder.typicode.com/todos/1")),
             Method = new(HttpMethods.Get),
             ExpectedStatusCodes =
             {
                  new HttpStatusCodeCase
                 {
                     StatusCode = StatusCodes.Status200OK,
                     Activity = new Sequence
                     {
                         Activities =
                         {
                             new Fault
                             {
                                 Message = new("Faulted")
                             }
                         }
                     }
                 }
             }
         },
        new WriteHttpResponse
        {
            Content = new(messageVariable)
        }
    }
};

And this throws.

Ui:

Image

API :

System.NullReferenceException: Object reference not set to an instance of an object.
   at Elsa.Http.Handlers.DefaultHttpEndpointFaultHandler.ContainsException(HttpEndpointFaultContext context, Type[] exceptionTypes)
   at Elsa.Http.Handlers.DefaultHttpEndpointFaultHandler.GetIsTimeoutFault(HttpEndpointFaultContext context)
   at Elsa.Http.Handlers.DefaultHttpEndpointFaultHandler.HandleAsync(HttpEndpointFaultContext context)
   at Elsa.Http.Middleware.HttpWorkflowsMiddleware.HandleWorkflowFaultAsync(IServiceProvider serviceProvider, HttpContext httpContext, RunWorkflowResult workflowExecutionResult, CancellationToken cancellationToken)
   at Elsa.Http.Middleware.HttpWorkflowsMiddleware.ExecuteWorkflowAsync(HttpContext httpContext, WorkflowGraph workflowGraph, RunWorkflowOptions workflowOptions, HttpEndpointBookmarkPayload bookmarkPayload, WorkflowInstance workflowInstance, IDictionary`2 input)
   at Elsa.Http.Middleware.HttpWorkflowsMiddleware.StartWorkflowAsync(HttpContext httpContext, StoredTrigger trigger, WorkflowGraph workflowGraph, IDictionary`2 input, String workflowInstanceId, String correlationId)
   at Elsa.Http.Middleware.HttpWorkflowsMiddleware.InvokeAsync(HttpContext httpContext, IServiceProvider serviceProvider)
   at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
   at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
   at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context)

Stacktrace of server

warn: Elsa.EntityFrameworkCore.Modules.Management.EFCoreWorkflowInstanceStore[0]
      Exception while deserializing workflow instance state: feab96070d415712. Reverting to default state
      System.Text.Json.JsonException: Deserialization failed for one of these reasons:
      1. A JSON object containing metadata for a nested array includes a non-metadata property '_type'.
      2. The JSON value could not be converted to System.Collections.Generic.ICollection`1[Elsa.Workflows.IActivity]. Path: $.activities._type | LineNumber: 0 | BytePositionInLine: 533.
         at System.Text.Json.ThrowHelper.ThrowJsonException(String message)
         at System.Text.Json.ThrowHelper.ThrowJsonException_MetadataInvalidPropertyInArrayMetadata(ReadStack& state, Type propertyType, Utf8JsonReader& reader)
         at System.Text.Json.Serialization.JsonCollectionConverter`2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value)
         at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
         at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
         at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
         at System.Text.Json.Serialization.Converters.ObjectWithParameterizedConstructorConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
         at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, T& value, JsonSerializerOptions options, ReadStack& state)
         at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.Deserialize(Utf8JsonReader& reader, ReadStack& state)
         at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.DeserializeAsObject(Utf8JsonReader& reader, ReadStack& state)
         at System.Text.Json.JsonSerializer.ReadFromSpanAsObject(ReadOnlySpan`1 utf8Json, JsonTypeInfo jsonTypeInfo, Nullable`1 actualByteCount)
         at System.Text.Json.JsonSerializer.Deserialize(JsonElement element, Type returnType, JsonSerializerOptions options)
         at Elsa.Workflows.ActivityFactory.Create(Type type, ActivityConstructorContext context)
         at Elsa.Workflows.ActivityDescriber.<>c__DisplayClass4_0.<DescribeActivityAsync>b__9(ActivityConstructorContext context)
         at Elsa.Workflows.Serialization.Converters.ActivityJsonConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options)
         at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
         at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
         at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
         at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, T& value, JsonSerializerOptions options, ReadStack& state)
         at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.Deserialize(Utf8JsonReader& reader, ReadStack& state)
         at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.DeserializeAsObject(Utf8JsonReader& reader, ReadStack& state)
         at System.Text.Json.JsonSerializer.ReadFromSpanAsObject(ReadOnlySpan`1 utf8Json, JsonTypeInfo jsonTypeInfo, Nullable`1 actualByteCount)
         at System.Text.Json.JsonSerializer.ReadFromSpanAsObject(ReadOnlySpan`1 json, JsonTypeInfo jsonTypeInfo)
         at System.Text.Json.JsonSerializer.Deserialize(String json, Type returnType, JsonSerializerOptions options)
         at Elsa.Workflows.Serialization.Converters.PolymorphicObjectConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options)
         at Elsa.Workflows.Serialization.Converters.PolymorphicDictionaryConverter.Read(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options)
         at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
         at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
         at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
         at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
         at System.Text.Json.Serialization.JsonCollectionConverter`2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value)
         at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
         at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
         at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
         at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, T& value, JsonSerializerOptions options, ReadStack& state)
         at System.Text.Json.Serialization.Metadata.JsonTypeInfo`1.Deserialize(Utf8JsonReader& reader, ReadStack& state)
         at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 utf8Json, JsonTypeInfo`1 jsonTypeInfo, Nullable`1 actualByteCount)
         at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 json, JsonTypeInfo`1 jsonTypeInfo)
         at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, JsonSerializerOptions options)
         at Elsa.Workflows.Serialization.Serializers.JsonWorkflowStateSerializer.Deserialize(String serializedState)
         at Elsa.EntityFrameworkCore.Modules.Management.EFCoreWorkflowInstanceStore.OnLoadAsync(ManagementElsaDbContext managementElsaDbContext, WorkflowInstance entity, CancellationToken cancellationToken)

manoelnunesborba avatar Nov 24 '25 16:11 manoelnunesborba