Skip to content

fix(mem_wal): allow append-only tables without primary keys#6848

Merged
jackye1995 merged 1 commit into
lance-format:mainfrom
touch-of-grey:RelaxPrimaryKey
May 19, 2026
Merged

fix(mem_wal): allow append-only tables without primary keys#6848
jackye1995 merged 1 commit into
lance-format:mainfrom
touch-of-grey:RelaxPrimaryKey

Conversation

@touch-of-grey
Copy link
Copy Markdown
Contributor

Summary

  • allow MemWAL initialization on append-only tables without unenforced primary key metadata
  • keep bucket sharding constrained to the primary key when a primary key exists, but allow no-PK tables to bucket by a non-nested column
  • update Rust, Python, and Java tests plus MemWAL docs

Fixes #6846

Tests

  • cargo fmt --all
  • cargo test -p lance test_initialize_mem_wal_bucket_sharding
  • uv run make build
  • uv run pytest python/tests/test_mem_wal.py::test_initialize_mem_wal_bucket_sharding_without_primary_key
  • git diff --check

Java tests were not run locally because this machine has no Java runtime installed.

Copy link
Copy Markdown

@claude claude Bot left a comment

Choose a reason for hiding this comment

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

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@github-actions github-actions Bot added bug Something isn't working A-python Python bindings A-java Java bindings + JNI labels May 19, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 19, 2026

Codecov Report

❌ Patch coverage is 91.37931% with 5 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
rust/lance/src/dataset/mem_wal/api.rs 72.22% 4 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

Copy link
Copy Markdown
Contributor

@jackye1995 jackye1995 left a comment

Choose a reason for hiding this comment

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

thanks for the fix

@jackye1995 jackye1995 merged commit 93fdd5d into lance-format:main May 19, 2026
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-java Java bindings + JNI A-python Python bindings bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Initializing MemWAL should not need primary key enforcement

2 participants