Skip to content

Fail Tool Calls #3215

Description

@zzyu17

Describe the bug

When configuring Copilot to use DeepSeek-V4 models (either Flash or Pro), 400 error occurs:

✗ 400 {"error":{"message":"messages.108: `tool_use` ids were found without `tool_result` blocks immediately after: call_8ZMDT1DJ43gofat5AalrxCTn. Each `tool_use` block must have a corresponding `tool_result` block in the next 
  message.","type":"invalid_request_error","param":null,"code":"invalid_request_error"}} 

Affected version

1.0.44

Steps to reproduce the behavior

No response

Expected behavior

No response

Additional context

  • OS: WSL2 (Ubuntu 24.04)
  • Config:
  export COPILOT_PROVIDER_BASE_URL="https://api.deepseek.com/anthropic"
  export COPILOT_PROVIDER_TYPE="anthropic"
  export COPILOT_MODEL="deepseek-v4-flash"/"deepseek-v4-pro"
  export COPILOT_PROVIDER_MAX_PROMPT_TOKENS="1000000"
  export COPILOT_PROVIDER_MAX_OUTPUT_TOKENS="384000"

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:modelsModel selection, availability, switching, rate limits, and model-specific behaviorarea:toolsBuilt-in tools: file editing, shell, search, LSP, git, and tool call behavior

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions