You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[bug] Gemini schema sanitization misses properties/required when type is undefined #13148
Confirmed — good catch. PR #11888 fixed the case where type is explicitly non-object, but missed when type is undefined.
Your proposed fix is correct. Per JSON Schema spec, a schema with properties/required but no explicit type should be treated as an implicit object. Adding type: "object" in that case fixes the issue.
The relevant code is in packages/opencode/src/provider/transform.ts:796:
Activity
fix(provider): infer type 'object' for schemas with properties but mi…
R44VC0RP commentedon Feb 11, 2026
Confirmed — good catch. PR #11888 fixed the case where
typeis explicitly non-object, but missed whentypeisundefined.Your proposed fix is correct. Per JSON Schema spec, a schema with
properties/requiredbut no explicittypeshould be treated as an implicit object. Addingtype: "object"in that case fixes the issue.The relevant code is in
packages/opencode/src/provider/transform.ts:796:Should add before this:
Feel free to open a PR with tests.
fix(google): sanitize unsupported JSON Schema keywords for Gemini API
github-actions commentedon Apr 13, 2026
To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.