{"record":{"id":"1d51a816462a9914","repo":"elsa-workflows/elsa-core","slug":"the-output-binding-has-no-converter-configuration","errorCode":null,"errorMessage":"The output binding has no converter configuration.","messagePattern":"The output binding has no converter configuration\\.","errorType":"exception","errorClass":"InvalidOperationException","httpStatus":null,"severity":"error","filePath":"src/modules/Elsa.Workflows.Core/Services/OutputConverterInvoker.cs","lineNumber":21,"sourceCode":"using Microsoft.Extensions.DependencyInjection;\n\nnamespace Elsa.Workflows;\n\n/// <inheritdoc />\npublic class OutputConverterInvoker(\n    IOutputConverterRegistry registry,\n    IOutputConverterSettingsValidator settingsValidator) : IOutputConverterInvoker\n{\n    /// <inheritdoc />\n    public object? Invoke(\n        ActivityExecutionContext activityExecutionContext,\n        Output output,\n        string outputName,\n        Type sourceType,\n        object value,\n        OutputBindingDestination destination)\n    {\n        var configuration = output.Converter ?? throw new InvalidOperationException(\"The output binding has no converter configuration.\");\n        var descriptor = registry.Find(configuration.Id);\n\n        if (descriptor == null)\n            throw CreateException(OutputConversionFailureStage.Resolution);\n\n        if (!IsRuntimeValueCompatible(value, sourceType) || !descriptor.SourceType.IsAssignableFrom(sourceType))\n            throw CreateException(OutputConversionFailureStage.SourceCompatibility);\n\n        if (!OutputConverterRegistry.IsAssignableToDestination(descriptor.ResultType, destination.Type))\n            throw CreateException(OutputConversionFailureStage.ResultValidation);\n\n        IOutputConverter converter;\n\n        try\n        {\n            converter = activityExecutionContext.WorkflowExecutionContext.ServiceProvider\n                .GetRequiredKeyedService<IOutputConverter>(configuration.Id);\n        }","sourceCodeStart":3,"sourceCodeEnd":39,"githubUrl":"https://github.com/elsa-workflows/elsa-core/blob/fe9217bdfa0e27f0e09e45006eb6898f616e513d/src/modules/Elsa.Workflows.Core/Services/OutputConverterInvoker.cs#L3-L39","documentation":"Thrown by OutputConverterInvoker.Invoke when an activity Output has no Converter configured. Elsa's output binding pipeline requires an OutputConverter (identified by an ID resolvable through the registry) to transform a raw output value into the destination type; without one the invocation cannot proceed.","triggerScenarios":"Accessing an output (e.g., GetResult/Get) whose Output instance was constructed manually or deserialized without setting Output.Converter, or writing a custom activity that creates Output objects without assigning a converter configuration.","commonSituations":"Hand-written activity outputs that bypass OutputDescriptor-driven creation, older workflow definitions persisted before converters were introduced being loaded by a newer runtime, and copy/pasted Output construction in custom activities.","solutions":["Assign a converter to the Output, typically via the OutputDescriptor so the correct OutputConverterConfiguration is created automatically.","If constructing Output manually, set output.Converter = new OutputConverter { Id = <registered converter id> } matching a converter registered in the OutputConverterRegistry.","Migrate/re-save legacy workflow definitions so outputs are rebuilt with converter configuration by the current activity descriptor.","If the value needs no conversion, use the default output helpers (e.g., Output<T> created through OutputReference/descriptor) rather than a bare Output."],"exampleFix":"// before\npublic Output MyOutput { get; set; } = new();\n\n// after: let the descriptor create a properly configured output\n[Output] public Output<int> MyOutput { get; set; } = default!;","handlingStrategy":"type-guard","validationCode":"if (output.Converter is null)\n    throw new InvalidOperationException($\"Output '{outputName}' has no converter configured; create outputs via their OutputDescriptor.\");","typeGuard":"bool HasConverter(Output? o) => o?.Converter is not null;","tryCatchPattern":"try\n{\n    var result = await OutputConverterInvoker.InvokeAsync(output, outputName, sourceType, value, destination);\n}\ncatch (InvalidOperationException ex) when (ex.Message.Contains(\"no converter configuration\"))\n{\n    logger.LogError(ex, \"Output {Name} lacks a converter; falling back to raw value\", outputName);\n}","preventionTips":["Declare outputs with [Output]-attributed properties so descriptors configure converters automatically.","Do not instantiate bare Output objects in custom activities.","Re-save legacy workflow definitions after upgrading so output metadata is rebuilt."],"tags":["output-converter","configuration","workflow"],"backgroundTag":"missing-required-config","analyzedSha":"fe9217bdfa0e27f0e09e45006eb6898f616e513d","analyzedAt":"2026-09-13T20:32:34.702Z","contentChangedAt":"2026-09-13T20:32:34.702Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}