Skip to content

v0.11.1

Choose a tag to compare

@github-actions github-actions released this 03 Nov 11:28
· 44 commits to main since this release

修复:draw openai 路径 400(n 类型错误)

v0.11.0 的 openai images adapter 把 n""1" 序列化成了字符串 "n":"1",Go 实现的网关(new-api 系)按 uint 解析 n 直接 400(cannot unmarshal string into Go struct field Alias.n of type uint)。已改为 JSON 数字 "n":1。

  • 影响范围:仅 openai images 路径;gemini 原生路径不受影响
  • 真实验证:magpie/gpt-image-2 经 new-api 网关 1K 生成 exit 0、22.1s、3.3MiB PNG

升级:bash install.sh 重跑即就地升级。

Changelog

  • be7125b fix: draw openai adapter 的 n 必须是 JSON 数字而非字符串——请求体误用 map[string]string 构造致 n 发出 "1",Go 实现的网关(new-api 系)把 n 解析为 uint 直接 400(v0.11.0 实弹事故:cannot unmarshal string into Go struct field Alias.n of type uint);golden 测试同步修正并锁死数字类型(原测试把错误形状锁进了断言——假网关不校验类型故全绿,用户附的真实可用 payload 一对照即现形)。真实验证:magpie/gpt-image-2 经 llmapi.ma.uy 1K 生成 exit 0、22.1s、3.3MiB PNG、画面经图像模型复核对题