Skip to content
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

GH-38039: [C++][Parquet] Fix segfault getting compression level for a Parquet column #38025

Merged
merged 2 commits into from
Oct 5, 2023

Conversation

adamreeve
Copy link
Contributor

@adamreeve adamreeve commented Oct 4, 2023

Rationale for this change

After the changes in #35886, getting the compression level for a Parquet column segfaults if the compression level or other options weren't previously set

What changes are included in this PR?

Adds a null check on the codec options of the column properties before trying to access the compression level.

Are these changes tested?

Yes, I added a unit test.

Are there any user-facing changes?

This fixes a regression added after 13.0.0 so isn't a user-facing fix

@mapleFU
Copy link
Member

mapleFU commented Oct 5, 2023

Would you mind create an issue for this? I guess this is not a "minor" fix for arrow github manangement

Copy link
Member

@mapleFU mapleFU left a comment

Choose a reason for hiding this comment

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

@github-actions github-actions bot added awaiting committer review Awaiting committer review and removed awaiting review Awaiting review labels Oct 5, 2023
@pitrou pitrou changed the title MINOR: [C++][Parquet] Fix segfault getting compression level for a Parquet column GH-38039: [C++][Parquet] Fix segfault getting compression level for a Parquet column Oct 5, 2023
@github-actions
Copy link

github-actions bot commented Oct 5, 2023

⚠️ GitHub issue #38039 has been automatically assigned in GitHub to PR creator.

Copy link
Member

@pitrou pitrou left a comment

Choose a reason for hiding this comment

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

+1, thanks a lot @adamreeve . I created an issue for this and will merge.

@pitrou pitrou merged commit 0fbfffb into apache:main Oct 5, 2023
33 of 34 checks passed
@pitrou pitrou removed the awaiting committer review Awaiting committer review label Oct 5, 2023
@adamreeve
Copy link
Contributor Author

Thanks for making the issue @pitrou, and apologies for not making one to start with, I should have read the contributing doc more closely

@adamreeve adamreeve deleted the compression_level_segfault branch October 5, 2023 20:30
@conbench-apache-arrow
Copy link

After merging your PR, Conbench analyzed the 6 benchmarking runs that have been run so far on merge-commit 0fbfffb.

There were 10 benchmark results indicating a performance regression:

The full Conbench report has more details.

JerAguilon pushed a commit to JerAguilon/arrow that referenced this pull request Oct 23, 2023
… for a Parquet column (apache#38025)

### Rationale for this change

After the changes in apache#35886, getting the compression level for a Parquet column segfaults if the compression level or other options weren't previously set

### What changes are included in this PR?

Adds a null check on the codec options of the column  properties before trying to access the compression level.

### Are these changes tested?

Yes, I added a unit test.

### Are there any user-facing changes?

This fixes a regression added after 13.0.0 so isn't a user-facing fix
* Closes: apache#38039

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Antoine Pitrou <antoine@python.org>
loicalleyne pushed a commit to loicalleyne/arrow that referenced this pull request Nov 13, 2023
… for a Parquet column (apache#38025)

### Rationale for this change

After the changes in apache#35886, getting the compression level for a Parquet column segfaults if the compression level or other options weren't previously set

### What changes are included in this PR?

Adds a null check on the codec options of the column  properties before trying to access the compression level.

### Are these changes tested?

Yes, I added a unit test.

### Are there any user-facing changes?

This fixes a regression added after 13.0.0 so isn't a user-facing fix
* Closes: apache#38039

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Antoine Pitrou <antoine@python.org>
dgreiss pushed a commit to dgreiss/arrow that referenced this pull request Feb 19, 2024
… for a Parquet column (apache#38025)

### Rationale for this change

After the changes in apache#35886, getting the compression level for a Parquet column segfaults if the compression level or other options weren't previously set

### What changes are included in this PR?

Adds a null check on the codec options of the column  properties before trying to access the compression level.

### Are these changes tested?

Yes, I added a unit test.

### Are there any user-facing changes?

This fixes a regression added after 13.0.0 so isn't a user-facing fix
* Closes: apache#38039

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Antoine Pitrou <antoine@python.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[C++][Parquet] Segfault getting compression level for a Parquet column
3 participants