Skip to content

[lance] Reject unsupported VARIANT and BLOB types in LanceFileFormat schema validation - #9150

Merged
JingsongLi merged 1 commit into
apache:masterfrom
thswlsqls:fix/lance-reject-variant-blob-types
Aug 10, 2026
Merged

[lance] Reject unsupported VARIANT and BLOB types in LanceFileFormat schema validation#9150
JingsongLi merged 1 commit into
apache:masterfrom
thswlsqls:fix/lance-reject-variant-blob-types

Conversation

@thswlsqls

Copy link
Copy Markdown
Contributor

Purpose

fix #9149

  • LanceRowTypeVisitor accepted VARIANT and BLOB, but the paimon-arrow bridge supports neither.
  • VARIANT writes succeed today, but SELECT * fails with a message-less UnsupportedOperationException in Arrow2PaimonVectorConverter#visit(VariantType) — the written column can never be read back. Rejecting it blocks silent data loss, not a working path.
  • BLOB reaches this visitor only through blob-descriptor-field / blob-view-field, which require data-evolution.enabled = true; those inline BLOBs already fail at INSERT. Managed BLOB columns in dedicated blob files are unaffected.
  • Matches VortexFileFormat and MosaicFileFormat, which reject both types, and follows [lance] Reject unsupported MULTISET type in LanceFileFormat schema validation #8678 (MULTISET).
  • Related: [lance] Reject unsupported element types nested in ARRAY #9102 (ARRAY element types, merged) — a different method in the same visitor.

Tests

  • Added LanceFileFormatTest#testValidateDataFields_UnsupportedVariantType and #testValidateDataFields_UnsupportedBlobType.
  • mvn -pl paimon-lance -DfailIfNoTests=false clean install (JDK 11) — 89 tests, 0 failures, 0 errors, 6 skipped. checkstyle, spotless and enforcer passed.

…schema validation

LanceRowTypeVisitor accepted VariantType and BlobType, but the
paimon-arrow bridge cannot convert either one. Reject both at schema
validation, matching the sibling Vortex and Mosaic formats.

Generated-by: Claude Code
@JingsongLi

Copy link
Copy Markdown
Contributor

+1

@JingsongLi
JingsongLi merged commit e274652 into apache:master Aug 10, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Lance file format accepts VARIANT and BLOB at schema validation but fails at read/write

2 participants