apache / apache/datafusion

Add defensive debug asserts in simplify to ensure schema doesn't change

Open
#18,001 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
9.3k
Forks
2.4k
Avg merge
3d 7h
Merged PRs (30d)
344

Description

Is it possible to be more defensive about this, such as a (debug) assert that checks this property at the callsite of simplify in the planner? 🤔

_Originally posted by @Jefffrey in https://github.com/apache/datafusion/pull/17981#pullrequestreview-3316979570_

Contributor guide

Open the contributing guide

Research direction

Review the original discussion in pull request #17981 and locate the planner callsites of simplify. Determine which schema property must remain unchanged, then add debug assertions and verify that the planner tests still pass.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
databases
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.