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
An error occurs when attempting to resume a suspended bookmark using the Elsa workflow framework, preventing the workflow from resuming successfully. Below is the detailed error stack trace.
Steps to Reproduce
To help us identify the issue more quickly, please follow these guidelines:
Detailed Steps: Provide a step-by-step description of what leads to the bug. Be as specific as possible.
Code Snippets:
protected override async ValueTask ExecuteAsync(ActivityExecutionContext context)
{
var eventName = EventName.Get(context) ?? "";
if (!context.IsTriggerOfWorkflow())
{
var book = new CreateBookmarkArgs()
{
Payload = eventName,
Callback = OnResumeAsync
};
context.CreateBookmark(book);
return;
}
await context.CompleteActivityAsync();
}
ResumeWorkflows code
var activityTypeName=ActivityTypeNameHelper.GenerateTypeName<FlowEvent>();
await _workflowRuntime.ResumeWorkflowsAsync(activityTypeName, bookMark, options);
Error Stack Trace:
at Elsa.Workflows.Services.ActivityFactory.ReadSyntheticInputs(ActivityDescriptor activityDescriptor, IActivity activity, JsonElement activityRoot, JsonSerializerOptions options)
at Elsa.Workflows.Services.ActivityFactory.Create(Type type, 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.JsonConverter`1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state)
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.JsonActivitySerializer.Deserialize(String serializedActivity)
at Elsa.Workflows.Management.Mappers.WorkflowDefinitionMapper.Map(WorkflowDefinition source)
at Elsa.Workflows.Management.Materializers.JsonWorkflowMaterializer.ToWorkflow(WorkflowDefinition definition)
at Elsa.Workflows.Management.Materializers.JsonWorkflowMaterializer.MaterializeAsync(WorkflowDefinition definition, CancellationToken cancellationToken)
at Elsa.Workflows.Management.Services.WorkflowDefinitionService.<MaterializeWorkflowAsync>d__4.MoveNext()
at Elsa.Workflows.Management.Services.WorkflowDefinitionService.<FindWorkflowGraphAsync>d__8.MoveNext()
at Elsa.Workflows.Runtime.Services.DefaultWorkflowRuntime.<ResumeWorkflowAsync>d__19.MoveNext()
at Elsa.Workflows.Runtime.Services.DefaultWorkflowRuntime.<ResumeWorkflowAsync>d__19.MoveNext()
at Elsa.Workflows.Runtime.Services.DefaultWorkflowRuntime.<ResumeWorkflowsAsync>d__32.MoveNext()
at Elsa.Workflows.Runtime.Services.DefaultWorkflowRuntime.<ResumeWorkflowsAsync>d__20.MoveNext()
at Danduola.IOTCoBotOS.Application.Workflow.FlowEvent.FlowEventWapper.<SubEvent>d__7.MoveNext() in E:\work\git\danduola.iotcobotos\API\Danduola.IOTCoBotOS.Application\Workflow\FlowEvent\FlowEventWapper.cs:line 131
Verify if the related activities contain custom fields or use custom types.
There may be issues with the data format of the suspended state or changes in activity definitions.
Suggested Fix or Investigation Areas:
Investigate the ReadSyntheticInputs method and its logic for parsing activity inputs.
Validate if ActivityJsonConverter and JsonSerializerOptions correctly register the required types and converters.
Provide additional documentation or debugging support for bookmark and activity serialization formats.
The text was updated successfully, but these errors were encountered:
Are you able to reproduce this in a small project using the latest 3.3-RC7 packages? If so, please share the project with me and I will troubleshoot the issue. Thanks.
Description
An error occurs when attempting to resume a suspended bookmark using the Elsa workflow framework, preventing the workflow from resuming successfully. Below is the detailed error stack trace.
Steps to Reproduce
To help us identify the issue more quickly, please follow these guidelines:
Detailed Steps: Provide a step-by-step description of what leads to the bug. Be as specific as possible.
Code Snippets:
ResumeWorkflows code
Error Stack Trace:
Environment:
Elsa Version: [3.2.3]
.NET Version: [..NET 8]
Database Provider: [Sqllite]
Hosting Environment: [Windows]
Additional Context:
Verify if the related activities contain custom fields or use custom types.
There may be issues with the data format of the suspended state or changes in activity definitions.
Suggested Fix or Investigation Areas:
Investigate the ReadSyntheticInputs method and its logic for parsing activity inputs.
Validate if ActivityJsonConverter and JsonSerializerOptions correctly register the required types and converters.
Provide additional documentation or debugging support for bookmark and activity serialization formats.
The text was updated successfully, but these errors were encountered: