Skip to content

fix: return error for divergent MemWAL schemas - #8198

Merged
Xuanwo merged 1 commit into
mainfrom
gatekeeper/fix-8194-1
Aug 4, 2026
Merged

fix: return error for divergent MemWAL schemas#8198
Xuanwo merged 1 commit into
mainfrom
gatekeeper/fix-8194-1

Conversation

@lance-gatekeeper

Copy link
Copy Markdown
Contributor

Summary

  • replace the fallible Lance-schema expect with a contextual InvalidInput error
  • add a regression test for an index column present only in the Arrow schema

Root cause

validate_index_configs checked the independent Arrow schema first and assumed that a matching Lance-schema field must exist. A caller-supplied divergent schema pair therefore reached expect and panicked at a public fallible API boundary.

Validation

  • cargo test -p lance test_validate_index_configs --lib
  • cargo fmt --all -- --check
  • cargo clippy --all --tests --benches -- -D warnings

Fixes #8194

@github-actions github-actions Bot added the bug Something isn't working label Aug 3, 2026

@lance-gatekeeper lance-gatekeeper Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gate recommendation: approve.

Schema divergence is now rejected at the side-effect-free validation boundary with a contextual InvalidInput, preserving the field-ID invariant and preventing malformed inputs from panicking.

@Xuanwo
Xuanwo merged commit b8bef59 into main Aug 4, 2026
40 checks passed
@Xuanwo
Xuanwo deleted the gatekeeper/fix-8194-1 branch August 4, 2026 05:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: validate_index_configs panics on Arrow/Lance schema divergence instead of returning an error

1 participant