Python Agent Framework sample fails to import with currently resolved SDK dependencies

Đang mở
#270 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
68/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
python
Lĩnh vực
backend

Hướng nghiên cứu

Bắt đầu trong thư mục python/agent-framework/sample-agent bằng cách tái hiện quá trình cài đặt uv và lệnh python -c "import agent", sau đó kiểm tra các import của sample và các khai báo dependency. Cập nhật sample để sử dụng các API có trong các dependency Agent Framework đã được phân giải, đồng thời xác minh bằng một smoke test rằng việc import ứng dụng và khởi tạo agent đều thành công.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Title: Python Agent Framework sample fails to import with currently resolved SDK dependencies

Description:

Summary

The Python Agent Framework sample uses SDK APIs that are unavailable in the dependency versions resolved during setup.

I encountered this in a local copy of the sample. I also checked upstream main on September 9, 2026 and confirmed that it contains the same imports and unconstrained Agent Framework dependency.

Sample: https://github.com/microsoft/Agent365-Samples/tree/main/python/agent-framework/sample-agent

Environment
  • macOS, Apple Silicon ARM64
  • Python 3.11.15
  • agent-framework-core==1.17.0
  • agent-framework-openai==1.14.2
  • agent-framework-azure-ai==1.0.0rc6
  • microsoft-agents-a365-tooling-extensions-agentframework==1.0.0
Steps to Reproduce

From an unmodified copy of the sample directory:

uv venv --python 3.11
source .venv/bin/activate
uv pip install -e .
python -c "import agent"

Dependency resolution can change over time; the versions above describe the environment where I observed the failure.

Actual Behavior

Importing the sample fails before startup or credential validation:

ImportError: cannot import name 'ChatAgent' from 'agent_framework'

After updating that import and its constructor locally, the next import fails:

ImportError: cannot import name 'AzureOpenAIChatClient' from 'agent_framework.azure'
Expected Behavior

Following the documented installation steps should produce an application that imports successfully with the resolved dependencies.

Suggested Resolution

Update the sample to APIs compatible with the Agent 365 integration and provide a tested dependency set. An import and agent-construction smoke test would help catch future SDK incompatibilities.

Ngôn ngữ chính
Python
Star
41
Fork
23
Merge trung bình
7 giờ 43 phút
Pull request đã merge (30 ngày)
3

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của microsoft/Agent365-python

Tất cả issue của microsoft/Agent365-python

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.