-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Incorrect lazy CSV select(len())
for compressed files
#18067
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #18067 +/- ##
==========================================
- Coverage 80.37% 80.35% -0.02%
==========================================
Files 1496 1496
Lines 197542 197545 +3
Branches 2820 2820
==========================================
- Hits 158771 158735 -36
- Misses 38249 38288 +39
Partials 522 522 ☔ View full report in Codecov by Sentry. |
067aea6
to
18dcecf
Compare
crates/polars-io/src/utils/other.rs
Outdated
@@ -47,9 +47,9 @@ pub fn get_reader_bytes<'a, R: Read + MmapBytesReader + ?Sized>( | |||
/// | |||
/// # Safety | |||
/// The `out` vec outlives `bytes` (declare `out` first). | |||
pub unsafe fn maybe_decompress_bytes<'a>( | |||
pub fn maybe_decompress_bytes<'a, 'b: 'a>( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
learned new things about lifetimes recently 😁
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then we can remove the # Safety
comment as well. 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have removed
actually, now I realize even 'a
is enough
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Format
Page
break; | ||
} | ||
|
||
reader_bytes = &reader_bytes[1..]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
skip empty lines at the start
Fixes #18057
Fixes #18070