Summary
All 7 active SamplesValidation tests in Microsoft.Agents.AI.Hosting.AzureFunctions.IntegrationTests fail consistently in the dotnet-test-functions CI job. The Azure Functions Core Tools (v4) can no longer auto-detect the worker runtime when launching the samples.
Failure signature
[dotnet(err)]: Can't determine project language from files. Please use one of [--dotnet-isolated, --dotnet, --javascript, --typescript, --python, --powershell, --custom, --go (preview)]
[dotnet(err)]: Worker runtime cannot be 'None'. Please set a valid runtime.
The Functions host process exits with code 1 before starting, causing WaitForFunctionsReadyAsync (AzureFunctionsTestHelper.cs:86) to throw InvalidOperationException.
Root cause analysis
- The CI setup action (
azure-functions-integration-setup) installs azure-functions-core-tools@4 via npm (floating version — picks up latest v4 patch).
- The samples'
local.settings.json files are .gitignore'd (they contain secrets), so they are never present in CI.
- The test helper (
SamplesValidation.StartFunctionApp) launches dotnet run with environment variables for OpenAI, storage, etc., but does NOT set FUNCTIONS_WORKER_RUNTIME.
- Previously the Functions host could infer
dotnet-isolated from the project structure; a recent v4 update appears to require explicit configuration.
Affected tests (all in SamplesValidation.cs)
SingleAgentSampleValidationAsync
MultiAgentOrchestrationConcurrentSampleValidationAsync
MultiAgentOrchestrationConditionalsSampleValidationAsync
SingleAgentOrchestrationHITLSampleValidationAsync
LongRunningToolsSampleValidationAsync
AgentAsMcpToolAsync
ReliableStreamingSampleValidationAsync
Example failing run
https://github.com/microsoft/agent-framework/actions/runs/27157145899/job/80162891404
Proposed fix
Add FUNCTIONS_WORKER_RUNTIME=dotnet-isolated to the environment variables set by StartFunctionApp in SamplesValidation.cs:
startInfo.EnvironmentVariables["FUNCTIONS_WORKER_RUNTIME"] = "dotnet-isolated";
Additionally consider pinning the Azure Functions Core Tools version in azure-functions-integration-setup/action.yml to prevent future breakage from floating versions.
Mitigation
Tests are temporarily skipped pending this fix.
Summary
All 7 active
SamplesValidationtests inMicrosoft.Agents.AI.Hosting.AzureFunctions.IntegrationTestsfail consistently in thedotnet-test-functionsCI job. The Azure Functions Core Tools (v4) can no longer auto-detect the worker runtime when launching the samples.Failure signature
The Functions host process exits with code 1 before starting, causing
WaitForFunctionsReadyAsync(AzureFunctionsTestHelper.cs:86) to throwInvalidOperationException.Root cause analysis
azure-functions-integration-setup) installsazure-functions-core-tools@4via npm (floating version — picks up latest v4 patch).local.settings.jsonfiles are.gitignore'd (they contain secrets), so they are never present in CI.SamplesValidation.StartFunctionApp) launchesdotnet runwith environment variables for OpenAI, storage, etc., but does NOT setFUNCTIONS_WORKER_RUNTIME.dotnet-isolatedfrom the project structure; a recent v4 update appears to require explicit configuration.Affected tests (all in SamplesValidation.cs)
SingleAgentSampleValidationAsyncMultiAgentOrchestrationConcurrentSampleValidationAsyncMultiAgentOrchestrationConditionalsSampleValidationAsyncSingleAgentOrchestrationHITLSampleValidationAsyncLongRunningToolsSampleValidationAsyncAgentAsMcpToolAsyncReliableStreamingSampleValidationAsyncExample failing run
https://github.com/microsoft/agent-framework/actions/runs/27157145899/job/80162891404
Proposed fix
Add
FUNCTIONS_WORKER_RUNTIME=dotnet-isolatedto the environment variables set byStartFunctionAppinSamplesValidation.cs:Additionally consider pinning the Azure Functions Core Tools version in
azure-functions-integration-setup/action.ymlto prevent future breakage from floating versions.Mitigation
Tests are temporarily skipped pending this fix.