Merge upstream/main into hosted-declarative

Resolve foundry_hosting/pyproject.toml conflict by keeping the loosened
azure-ai-agentserver-* pins (>=X.Y.ZbN,<NEXT_MAJOR) while taking main's
agent-framework-core>=1.2.1,<2 bump.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
alliscode
2026-04-28 13:36:50 -07:00
Unverified
109 changed files with 2096 additions and 828 deletions
@@ -277,11 +277,11 @@ __all__ = [
"USER_AGENT_TELEMETRY_DISABLED_ENV_VAR",
"Agent",
"AgentContext",
"AgentFrameworkException",
"AgentEvalConverter",
"AgentExecutor",
"AgentExecutorRequest",
"AgentExecutorResponse",
"AgentFrameworkException",
"AgentMiddleware",
"AgentMiddlewareLayer",
"AgentMiddlewareTypes",
@@ -79,9 +79,11 @@ def _detect_hosted_environment() -> None:
except (ModuleNotFoundError, ValueError):
return
with contextlib.suppress(ImportError, AttributeError):
from azure.ai.agentserver.core import AgentConfig # pyright: ignore[reportMissingImports]
from azure.ai.agentserver.core import ( # pyright: ignore[reportMissingImports]
AgentConfig, # pyright: ignore[reportUnknownVariableType]
)
if AgentConfig.from_env().is_hosted:
if AgentConfig.from_env().is_hosted: # pyright: ignore[reportUnknownMemberType]
_add_user_agent_prefix(_HOSTED_USER_AGENT_PREFIX)
_hosted_env_detected = True
+1 -1
View File
@@ -4,7 +4,7 @@ description = "Microsoft Agent Framework for building AI Agents with Python. Thi
authors = [{ name = "Microsoft", email = "af-support@microsoft.com"}]
readme = "README.md"
requires-python = ">=3.10"
version = "1.2.0"
version = "1.2.1"
license-files = ["LICENSE"]
urls.homepage = "https://aka.ms/agent-framework"
urls.source = "https://github.com/microsoft/agent-framework/tree/main/python"
@@ -2,8 +2,6 @@
"""Tests for AgentFrameworkException inner_exception handling."""
import pytest
from agent_framework import AgentFrameworkException