Skip to content

fix: read turn_id instead of turn from Copilot SDK events#85

Open
taipoweredpm wants to merge 1 commit intomicrosoft:mainfrom
taipoweredpm:fix/copilot-turn-id
Open

fix: read turn_id instead of turn from Copilot SDK events#85
taipoweredpm wants to merge 1 commit intomicrosoft:mainfrom
taipoweredpm:fix/copilot-turn-id

Conversation

@taipoweredpm
Copy link
Copy Markdown

@taipoweredpm taipoweredpm commented Apr 10, 2026

Summary

Fixes the web dashboard showing Turn ? instead of the actual turn number when using the Copilot provider.

Root Cause

The Copilot SDK exposes the turn number as urn_id on �vent.data, not urn. The two getattr(event.data, "turn", ...) calls in CopilotProvider always returned None, causing the dashboard's nullish fallback to render "Turn ?".

Changes

Two-line fix in src/conductor/providers/copilot.py:

  • _log_event_verbose (line 1123): getattr(event.data, "turn", None) → getattr(event.data, "turn_id", None)
  • _forward_event (line 1180): getattr(event.data, "turn", None) → getattr(event.data, "turn_id", None)

The callback payload key remains "turn" — only the SDK attribute name changes.

Fixes #62

The Copilot SDK exposes the turn number as 'turn_id' on event.data,
not 'turn'. The incorrect attribute name caused getattr to always
return None, resulting in 'Turn ?' in the web dashboard and missing
turn info in console output.

Fixes microsoft#62

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Copilot provider: Web dashboard shows "Turn ?" instead of turn number (wrong attribute name)

2 participants