delta-io / delta-io/delta-kernel-rs

Remove embedded output_schema from ParseJsonExpression, use result_type instead

Open
#1,981 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
362
Forks
217
Avg merge
2d 16h
Merged PRs (30d)
91

Description

Summary

ParseJsonExpression currently embeds its output_schema in the expression struct. This is redundant — the evaluator framework already threads result_type through evaluate_expression, which carries the same schema information.

MapToStruct was recently refactored (in #1895) to use result_type instead of an embedded schema, consistent with how Struct expressions work. ParseJson should follow the same pattern for consistency.

Changes needed

  • Remove output_schema from ParseJsonExpression
  • Update evaluate_expression to use result_type for ParseJson (matching the Struct and MapToStruct pattern)
  • Update the Expression::parse_json factory method
  • Update FFI visitor/engine_visitor (remove schema handle parameter)
  • Update transforms, Display, tests

Context

See discussion in #1895 (nicklan's comment).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the MapToStruct refactor in #1895 and trace how result_type is passed through evaluate_expression for Struct and MapToStruct. Then inspect Expression::parse_json, the FFI visitor and engine_visitor, transforms, Display, and the existing tests. Done means ParseJsonExpression no longer stores output_schema and all listed callers and tests use the result_type-based path.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
api, backend
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.