fix(mcp): preserve nullable schema coercion

This commit is contained in:
Pony.Ma 2026-04-28 12:25:10 +08:00 committed by Teknium
parent 1350d12b0b
commit aa94883288
4 changed files with 66 additions and 5 deletions

View file

@ -285,6 +285,7 @@ class TestSchemaConversion:
assert schema["properties"]["workdir"] == {
"type": "string",
"nullable": True,
"default": None,
"description": "Optional working directory",
}
@ -314,6 +315,7 @@ class TestSchemaConversion:
assert schema["properties"]["filters"]["items"] == {
"type": "object",
"properties": {"field": {"type": "string"}},
"nullable": True,
}
def test_convert_mcp_schema_survives_missing_inputschema_attribute(self):