Skip to content

[Bug] Question dock can show [object Object] after answering #837

@Astro-Han

Description

@Astro-Han

What happened?

When the assistant asks a question through the question dock, choosing an option can show a toast with:

请求失败
[object Object]

The observed session export shows the answer was actually accepted and the assistant continued with the chosen action. The user-visible failure is therefore misleading: the app reports a raw object instead of a readable response-state message.

Affected observed case:

  • Question: 怎么处理这个 perf CI?
  • Selected answer: 重跑 failed job
  • Session export: docs/debug-session-log/pawwork-session-nimble-engine-2026-05-21-14-47-54-question-failed.json
  • App version in export: 0.0.0-prod-202605201748

Which area seems affected?

App flow or product behavior; UI or design system; Model harness, prompts, tools, or session mechanics.

How much does this affect you?

Breaks an important workflow. The question dock is a decision point; showing [object Object] makes it look like the answer failed even when it may have succeeded.

Steps to reproduce

  1. Open a session where the assistant calls the question tool.
  2. Choose an option in the question dock and submit.
  3. In the observed failure, a toast appears: 请求失败 [object Object].
  4. The session export still shows the question tool completed with the selected answer and the assistant continued.

Potentially related reproduction path: submit the same question response again while the external-result entry has already been resolved, or while the dock remains visible before SSE/global sync removes it.

What did you expect to happen?

  • If the answer is accepted, the dock should close or become non-interactive without showing a failure toast.
  • If the answer was already accepted elsewhere or by an earlier click, the app should treat that as an idempotent completion, not a user-facing failure.
  • If the response really is stale/invalid, the toast should use readable copy, never [object Object].

PawWork version

0.0.0-prod-202605201748

OS version

macOS 25.5.0 from the session export.

Can you reproduce it again?

Sometimes / observed from session export and screenshot.

Diagnostics

Evidence from the session export:

  • The question tool part is completed and contains the selected answer:
    • state.output: User has answered your questions: "怎么处理这个 perf CI?"="重跑 failed job"...
  • The assistant then executed the chosen action:
    • gh run rerun 26230861270 --failed
    • exit 0

Likely involved code paths:

  • packages/app/src/pages/session/composer/session-question-dock.tsx
  • packages/sdk/js/src/v2/gen/client/client.gen.ts
  • packages/opencode/src/server/instance/session.ts
  • packages/opencode/src/tool/external-result.ts

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Medium priorityappApplication behavior and product flowsbugSomething isn't workingharnessModel harness, prompts, tool descriptions, and session mechanicsuiDesign system and user interface

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions