mirror of
https://github.com/zed-industries/zed.git
synced 2026-05-30 03:34:30 +00:00
Closes #34314 This PR resolves an issue where serde(untagged) caused Rust None values to serialize as null, which OpenRouter's Mistral API (when tool_choice is present) incorrectly interprets as a defined value, leading to a 400 error. By replacing serde(untagged) with serde(snake_case), None values are now correctly omitted from the serialized JSON, fixing the problem. P.S. A separate PR will address serde(untagged) usage for other providers, as null is not expected for them either. Release Notes: - Fix ToolChoice getting serialized to null on OpenRouter |
||
|---|---|---|
| .. | ||
| src | ||
| Cargo.toml | ||
| LICENSE-GPL | ||