fix(provider): sortable_chunk_fields needs required type — handshake was broken
DEPLOY-BREAKER caught by driving the live bind (unit tests + worldtree-dev's
name-only parser + heid-bug-hunt all missed it). bifrost handshake_response
`SortableChunkField` requires BOTH `name` and `type` (additionalProperties:false).
We advertised `[{"name":"updated_at"}]` (no `type`), so the handshake_response
failed wire-schema validation → `bifrost.schema_validation_failed` → the ENTIRE
Bifrost bind (memory + affect) broke, not just the sort. Advertise
`{"name":"updated_at","type":"timestamp"}` (matches the reference; `type` is
advisory-only). Regression guard added to the caps test (asserts required name+type,
no extra keys). Full suite 639 green.
This commit is contained in:
@@ -62,6 +62,15 @@ def test_fresh_db_advertises_v1_caps_and_schema():
|
||||
assert caps["atomic_supersede_supported"] is False
|
||||
assert caps["transaction_supported"] is False
|
||||
assert caps["filterable_metadata_fields"] == []
|
||||
# bifrost handshake_response SortableChunkField requires BOTH name + type
|
||||
# (additionalProperties:false) — omitting `type` fails wire-schema validation and
|
||||
# breaks the ENTIRE Bifrost bind (regression guard: the deploy-breaker of 2026-07-15).
|
||||
scf = caps["sortable_chunk_fields"]
|
||||
assert scf == [{"name": "updated_at", "type": "timestamp"}]
|
||||
for entry in scf:
|
||||
assert set(entry) == {"name", "type"} # required exactly, no extra keys
|
||||
assert isinstance(entry["name"], str) and entry["name"]
|
||||
assert isinstance(entry["type"], str) and entry["type"]
|
||||
# tables + vec index queryable
|
||||
store._conn.execute("SELECT * FROM memory_chunks")
|
||||
store._conn.execute("SELECT * FROM memory_idempotency")
|
||||
|
||||
Reference in New Issue
Block a user