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
{{ message }}
Repository navigation
.NET: [Bug]: Provided Human in the loop sample does not seem to work anymore with RC1 #4144
Which is a Human in the Loop sample... This seems not to work anymore with RC1 (If you guess a number, the sample just ends with no feedback or giving user the option to retry)
think i got the same error in my application. Also worked previously (with the change i converted it to the [MessageHandler] way).
System.InvalidOperationException: Executor 'CodeGenerationOrchestrator' cannot send messages of type 'GSL.Dev.Agents.Executors.CodeGeneration.ReviewRequest'.
at Microsoft.Agents.AI.Workflows.InProc.InProcessRunnerContext.SendMessageAsync(String sourceId, Object message, String targetId, CancellationToken cancellationToken)
at GSL.Dev.Agents.Executors.CodeGeneration.CodeGenerationOrchestrator.HandleAsync(TestGenerationResult testResult, IWorkflowContext context, CancellationToken cancellationToken) in D:\projects\CodingAgent\GSL.Dev.Agents\Executors\CodeGeneration\CodeGenerationOrchestrator.cs:line 117
at Microsoft.Agents.AI.Workflows.RouteBuilder.<>c__DisplayClass12_0`1.<<AddHandler>g__WrappedHandlerAsync|0>d.MoveNext()
--- End of stack trace from previous location ---
at Microsoft.Agents.AI.Workflows.Execution.MessageRouter.RouteMessageAsync(Object message, IWorkflowContext context, Boolean requireRoute, CancellationToken cancellationToken)
Which is a Human in the Loop sample... This seems not to work anymore with RC1 (If you guess a number, the sample just ends with no feedback or giving user the option to retry)
System.InvalidOperationException: 'Executor 'Evaluator and Hint-giver' cannot send messages of type 'FeedbackToUser'.'
when run... This sample worked flawlessly pre RC1
Any hints as to what is going on here?
Code Sample
Error Messages / Stack Traces
Package Versions
RC1
.NET Version
.NET10
Additional Context
No response
For the first example, you can fix it by adding the attributes [YieldsOutput(typeof(string))] and [SendsMessage(typeof(NumberSignal))] to the JudgeExecutor class. For the second example, I haven’t tested it, but since it’s the same error, I believe adding the attributes [YieldsOutput(typeof(string))] and [SendsMessage(typeof(FeedbackToUser))] to the EvaluateAndHintExecutor class should resolve it.
I’m not sure. I tried it after noticing the presence of another attribute, [MessageHandler], in a different example and I also didn’t see anything in the documentation.
Unfortunatelly the workaround with [YieldsOutput(typeof(string))] [SendsMessage(typeof(NumberSignal))] internal sealed class JudgeExecutor() : Executor<int>("Judge") ddnt solved it.
mfoosSit If you use context.SendMessageAsync, you should annotate the class with the SendsMessage attribute, and the type passed to typeof must be the type expected by the next executor.
You didn’t provide any code snippet, but based on the error message it will probably be:
Activity
codehunter13 commentedon Feb 22, 2026
think i got the same error in my application. Also worked previously (with the change i converted it to the [MessageHandler] way).
rogeriorfp commentedon Feb 24, 2026
For the first example, you can fix it by adding the attributes [YieldsOutput(typeof(string))] and [SendsMessage(typeof(NumberSignal))] to the JudgeExecutor class. For the second example, I haven’t tested it, but since it’s the same error, I believe adding the attributes [YieldsOutput(typeof(string))] and [SendsMessage(typeof(FeedbackToUser))] to the EvaluateAndHintExecutor class should resolve it.
rwjdk commentedon Feb 24, 2026
Thanks... That works 🙌.
Is what we just did a workaround or a mandatory part of workflow now (I did not see anything like this mentioned in any documentation)
rogeriorfp commentedon Feb 24, 2026
I’m not sure. I tried it after noticing the presence of another attribute, [MessageHandler], in a different example and I also didn’t see anything in the documentation.
rogeriorfp commentedon Feb 24, 2026
I believe this will become mandatory based on pull request #3792.
mfoosSit commentedon Mar 6, 2026
I got the same issue.

Unfortunatelly the workaround with
[YieldsOutput(typeof(string))] [SendsMessage(typeof(NumberSignal))] internal sealed class JudgeExecutor() : Executor<int>("Judge")ddnt solved it.rogeriorfp commentedon Mar 6, 2026
mfoosSit If you use
context.SendMessageAsync, you should annotate the class with theSendsMessageattribute, and the type passed totypeofmust be the type expected by the next executor.You didn’t provide any code snippet, but based on the error message it will probably be:
[SendsMessage(typeof(ChatMessage))]