fix(search): preserve compound requested fields - #1325
Conversation
Signed-off-by: imi <hoshinoimi@gmail.com>
|
Reviewed this properly, and the short version is: it is ready, and we would like to merge it as shown — may we? It is still marked draft, so I am asking rather than just merging. If you were planning further changes, say so and we will wait. If draft is simply left over, mark it ready (or reply here) and it goes in. What I verified, since it is worth knowing the review was real: The bug reproduces on today's What I liked is that you did not patch one emitter. You found all three duplicated scalar-only switches — table, skeleton tree, and JSON — and centralised the cell logic into The type-preservation split is the right call too: compact JSON where the output has to stay inside one table cell, and I also checked the text path stays safe: compact JSON contains Both regression tests bind. Reverting the fix turns the text assert red ( No defects found. Two entirely optional notes:
Thank you for the minimal public repro in #1284 as well — it made confirming both the symptom and the fix scope trivial, and that is a real kindness to whoever reviews. |
What does this PR do?
Fixes #1284.
Requested extra fields in
search_graphwere serialized only for scalar JSON values. Stored arrays and objects fell through to an empty cell in table output and were silently misrepresented.This change centralizes requested-field serialization: table output emits compact JSON text for compound values, while JSON output copies the original JSON value so its type is preserved. Regression coverage verifies both output formats.
Verification
make -f Makefile.cbm test-focused TEST_SUITES='cypher extraction registry pipeline mcp index_resilience'Checklist
git commit -s) and follows the Contributor License Agreementmake -f Makefile.cbm test) — focused sanitized suites passedmake -f Makefile.cbm lint-ci) — not run locally