.NET: runtime logs forwarding session.idle, but SDK callback never delivers it
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 42/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- csharp
- Lĩnh vực
- api, backend-api-design, distributed-systems
Hướng nghiên cứu
Không có tệp cụ thể nào được nêu tên. Hãy bắt đầu bằng cách lần theo đường dẫn đăng ký session .NET và điều phối FIFO, sau đó kiểm tra hợp đồng runtime được đề xuất của session.waitForIdle cùng với cách xử lý session.idle và GetEventsAsync. Hoàn thành có nghĩa là một bài kiểm thử hồi quy cho thấy việc hoàn tất chờ tất cả các sự kiện đứng trước, xử lý các thông báo idle bị loại bỏ, đưa lỗi ra ngoài và hỗ trợ hủy.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Summary
Visual Studio can remain indefinitely in the running state after the Copilot CLI has completed a response.
The CLI verbose log shows that it forwarded the terminal, ephemeral session.idle event. The .NET SDK subscription receives the preceding events, including the final assistant.turn_end, but never receives SessionIdleEvent.
Because session.idle is ephemeral, it cannot be recovered later through GetEventsAsync(). The client therefore has no authoritative completion signal and continues waiting.
Environment
- GitHub.Copilot.SDK:
1.0.1 - Copilot CLI runtime:
1.0.61 - Windows ARM64
- Visual Studio Agent and Agent (Preview) modes
The current SDK 1.0.7 still does not expose a durable idle wait or event-dispatch flush API.
Observed behavior
The CLI log ends with:
Forwarding event ... assistant.turn_end
Forwarding event ... session.idle (ephemeral)
The .NET subscriber observes assistant.turn_end, but not session.idle. The operation remains active even though the runtime has finished.
The absence of session.idle from events.jsonl is expected because the event is ephemeral; it does not explain why the live subscriber missed it.
Why assistant.turn_end is insufficient
In multi-turn tool workflows, an intermediate assistant.turn_end can be followed immediately by another assistant.turn_start. Completion also needs to account for sub-agents, attached shells, queued messages, and follow-up notification turns.
Requested fix
Please provide an authoritative completion contract owned by the runtime/SDK, for example:
await session.WaitForIdleAsync(cancellationToken);
It should:
- Wait for turns, sub-agents, attached shells, queued work, and follow-up turns to settle.
- Resolve only when the runtime is fully idle.
- Ensure preceding session events have crossed the .NET SDK FIFO dispatch queue.
- Surface session errors and transport failures.
- Remain correct if the live
session.idlenotification is dropped. - Support cancellation without leaving an orphaned waiter.
An equivalent session.waitForIdle runtime RPC combined with an SDK dispatch barrier would also work.
Regression test
Add a .NET test where a multi-turn response completes, the live session.idle notification is deliberately dropped, and the completion wait still resolves only after all preceding assistant and tool events have been delivered.
Related
- #794 - identifies missing
session.idleand silent notification drops, but its proposed fallback did not ship - #558 - timeout waiting for
session.idle - #791 - serialized FIFO event dispatch in the .NET SDK
- #927 - ephemeral events are intentionally unavailable through replay
- #1275 -
assistant.turn_endalone is not a completion signal
- Ngôn ngữ chính
- Java
- Star
- 10.5k
- Fork
- 1.5k
- Merge trung bình
- 1 ngày 9 giờ
- Pull request đã merge (30 ngày)
- 130
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của github/copilot-sdk
-
agentic-workflows
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
github/copilot-sdk#2760 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
github/copilot-sdk#2759 ·
-
documentation
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
github/copilot-sdk#2758 ·
-
agentic-workflows
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
github/copilot-sdk#2709 · 1 bình luận ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 78/100
github/copilot-sdk#2673 ·
Tất cả issue của github/copilot-sdk
Issue tương tự
-
executions.Query — startDate and timeRange filters are sent with inverted comparison operators Đang mởarea/plugin
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
kestra-io/plugin-kestra#190 ·
-
litertlm-android AAR ships no consumer ProGuard rules → "mid == null" SIGABRT in minified apps Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
google-ai-edge/LiteRT-LM#3739 ·
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
Add canonical URLs and a sitemap Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
integra-team-red/meet-map#249 ·
-
[Studio][Bug] Cancelled create-user dialog keeps the password and admin switch for the next attempt Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
apache/rocketmq-dashboard#5064 ·