-
Notifications
You must be signed in to change notification settings - Fork 915
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
[Java] ArrowIPCTableWriter writes en empty batch in the case of an empty table. #11883
Conversation
Signed-off-by: Liangcai Li <[email protected]>
Codecov ReportBase: 87.40% // Head: 87.48% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## branch-22.12 #11883 +/- ##
================================================
+ Coverage 87.40% 87.48% +0.07%
================================================
Files 133 133
Lines 21833 21866 +33
================================================
+ Hits 19084 19129 +45
+ Misses 2749 2737 -12
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
boolean done = false; | ||
int count = 0; | ||
while (!done) { | ||
try (Table t = reader.getNextIfAvailable()) { | ||
if (t == null) { | ||
done = true; | ||
} else { |
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.
Nit: We can do this:
boolean done = false; | |
int count = 0; | |
while (!done) { | |
try (Table t = reader.getNextIfAvailable()) { | |
if (t == null) { | |
done = true; | |
} else { | |
int count = 0; | |
while (true) { | |
try (Table t = reader.getNextIfAvailable()) { | |
if (t == null) { | |
break; | |
} else { |
@gpucibot merge |
closes #11882
Updated the
ArrowIPCTableWriter
to write en empty batch explicitly in the case of an empty table, because the Arrow IPC writer will write no batches out for this case, leading to an error as below when calling thePyarrow.Table.from_batches
without specifying a schema.Signed-off-by: Liangcai Li [email protected]
Checklist