-
-
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
feat: Include file path option for NDJSON #17681
Conversation
@@ -40,6 +40,18 @@ impl JsonExec { | |||
|
|||
let mut n_rows = self.file_scan_options.n_rows; | |||
|
|||
// Avoid panicking | |||
if n_rows == Some(0) { |
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.
drive-by - fix panic on scan_ndjson().head(0)
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.
Can you add a test for this one?
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.
added a test below
FileScan::Csv { .. } => true, | ||
#[cfg(feature = "json")] | ||
FileScan::NDJson { .. } => true, | ||
FileScan::Anonymous { .. } => false, |
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.
make sure the lazy schema is correct
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #17681 +/- ##
==========================================
- Coverage 80.67% 80.64% -0.03%
==========================================
Files 1490 1490
Lines 195931 196029 +98
Branches 2789 2789
==========================================
+ Hits 158059 158087 +28
- Misses 37359 37429 +70
Partials 513 513 ☔ View full report in Codecov by Sentry. |
ref #10481