mirror of
https://github.com/microsoft/autogen.git
synced 2025-09-25 16:16:37 +00:00
fix: Increase MethodGroup type precision
* Fixes stackoverflow when calling InMemoryRutnime.RegisterAgentFactoryAsync()
This commit is contained in:
parent
d9e0013975
commit
c930251ebc
@ -176,7 +176,7 @@ public sealed class InProcessRuntime : IAgentRuntime
|
||||
}
|
||||
|
||||
public ValueTask<AgentType> RegisterAgentFactoryAsync<TAgent>(AgentType type, Func<AgentId, IAgentRuntime, ValueTask<TAgent>> factoryFunc) where TAgent : IHostableAgent
|
||||
=> this.RegisterAgentFactoryAsync(type, async (agentId, runtime) => await factoryFunc(agentId, runtime));
|
||||
=> this.RegisterAgentFactoryAsync(type, async ValueTask<IHostableAgent> (agentId, runtime) => await factoryFunc(agentId, runtime));
|
||||
|
||||
public ValueTask<AgentType> RegisterAgentFactoryAsync(AgentType type, Func<AgentId, IAgentRuntime, ValueTask<IHostableAgent>> factoryFunc)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user