Skip to content

feat: add variable packed struct support#5003

Merged
Xuanwo merged 18 commits intomainfrom
packed-strut-with-utf8
Oct 22, 2025
Merged

feat: add variable packed struct support#5003
Xuanwo merged 18 commits intomainfrom
packed-strut-with-utf8

Conversation

@Xuanwo
Copy link
Copy Markdown
Collaborator

@Xuanwo Xuanwo commented Oct 20, 2025

Close #2862

This PR will add variable packed struct support in file version 2.2


This PR was primarily authored with Codex using GPT-5-Codex and then hand-reviewed by me. I AM responsible for every change made in this PR. I aimed to keep it aligned with our goals, though I may have missed minor issues. Please flag anything that feels off, I'll fix it quickly.

Signed-off-by: Xuanwo <github@xuanwo.io>
Signed-off-by: Xuanwo <github@xuanwo.io>
Signed-off-by: Xuanwo <github@xuanwo.io>
Signed-off-by: Xuanwo <github@xuanwo.io>
@github-actions github-actions Bot added enhancement New feature or request python labels Oct 20, 2025
@Xuanwo
Copy link
Copy Markdown
Collaborator Author

Xuanwo commented Oct 21, 2025

@codex review

@chatgpt-codex-connector
Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Can't wait for the next one!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Member

@westonpace westonpace left a comment

Choose a reason for hiding this comment

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

This is great! This is exactly what I had in mind for per-value packed struct 👍

Comment thread rust/lance-encoding/src/compression.rs
Comment thread rust/lance-encoding/src/compression.rs
Comment thread rust/lance-encoding/src/encodings/logical/primitive.rs Outdated
Comment thread rust/lance-encoding/src/encodings/logical/primitive.rs
Comment thread rust/lance-encoding/src/encodings/physical/packed.rs
Comment thread rust/lance-encoding/src/encodings/physical/packed.rs
Comment thread rust/lance-encoding/src/encodings/physical/packed.rs Outdated
Comment thread rust/lance-encoding/src/encodings/physical/packed.rs Outdated
Signed-off-by: Xuanwo <github@xuanwo.io>
@Xuanwo
Copy link
Copy Markdown
Collaborator Author

Xuanwo commented Oct 21, 2025

Test failure fixed by #5025, will continue after #5025 been merged.

@codecov-commenter
Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 73.15789% with 204 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.71%. Comparing base (846effe) to head (7f36e32).
⚠️ Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
...st/lance-encoding/src/encodings/physical/packed.rs 73.95% 149 Missing and 20 partials ⚠️
rust/lance-encoding/src/compression.rs 66.15% 18 Missing and 4 partials ⚠️
.../lance-encoding/src/encodings/logical/primitive.rs 42.85% 11 Missing and 1 partial ⚠️
rust/lance-encoding/src/data.rs 93.75% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5003      +/-   ##
==========================================
- Coverage   81.75%   81.71%   -0.04%     
==========================================
  Files         340      340              
  Lines      137595   138416     +821     
  Branches   137595   138416     +821     
==========================================
+ Hits       112487   113104     +617     
- Misses      21372    21550     +178     
- Partials     3736     3762      +26     
Flag Coverage Δ
unittests 81.71% <73.15%> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Xuanwo Xuanwo merged commit add6fa6 into main Oct 22, 2025
31 checks passed
@Xuanwo Xuanwo deleted the packed-strut-with-utf8 branch October 22, 2025 12:36
jackye1995 pushed a commit to jackye1995/lance that referenced this pull request Jan 21, 2026
Close lance-format#2862

This PR will add variable packed struct support in file version 2.2

---

**This PR was primarily authored with Codex using GPT-5-Codex and then
hand-reviewed by me. I AM responsible for every change made in this PR.
I aimed to keep it aligned with our goals, though I may have missed
minor issues. Please flag anything that feels off, I'll fix it
quickly.**

---------

Signed-off-by: Xuanwo <github@xuanwo.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow packing of variable length columns

3 participants