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

[BUG] Pass parquet2 io errors correctly into arrow2 #3012

Conversation

desmondcheongzx
Copy link
Contributor

@desmondcheongzx desmondcheongzx commented Oct 7, 2024

In 7fe3dbc, two changes were made that caused parquet2 io errors to be mishandled.

Firstly, a IoError for parquet2 was introduced. However in the implementation of parquet2::error::Error for arrow2::error:Error, any parquet2 error that is not FeatureNotActive or Transport is transformed into an ExternalFormat error.

Secondly, arrow2 IO errors are intended to be marked as ByteStreamErrors, primarily so that they are handled as transient errors and can be retried appropriately. However this special case was removed.

This PR makes now classifies parquet2 io errors as arrow2 io errors, and arrow2 io errors are now marked as ByteStreeamErrors.

@github-actions github-actions bot added the bug Something isn't working label Oct 7, 2024
Copy link

codspeed-hq bot commented Oct 7, 2024

CodSpeed Performance Report

Merging #3012 will not alter performance

Comparing desmondcheongzx:fix-parquet2-arrow2-io-errors (6b71903) with main (272163f)

Summary

✅ 17 untouched benchmarks

src/arrow2/src/io/parquet/mod.rs Show resolved Hide resolved
@@ -14,7 +14,7 @@ pub enum DaftError {
#[error("DaftError::ComputeError {0}")]
ComputeError(String),
#[error("DaftError::ArrowError {0}")]
ArrowError(#[from] arrow2::error::Error),
ArrowError(String),
Copy link
Member

Choose a reason for hiding this comment

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

This can still hold arrow2::error::Error instead of a string

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah gotcha, done

src/arrow2/src/io/parquet/mod.rs Show resolved Hide resolved
@raunakab
Copy link
Contributor

raunakab commented Oct 7, 2024

Sorry for the regression, folks. I must have accidentally removed a From implementation that shouldn't have been removed.

desmondcheongzx and others added 4 commits October 7, 2024 14:21
- feature flag was incorrect
    - incorrectly masked the test!
- parquet2 is required, but *only* as a test dep!
    - therefore, added it as a `[dev-dependency]`
@desmondcheongzx desmondcheongzx enabled auto-merge (squash) October 7, 2024 21:54
@desmondcheongzx desmondcheongzx merged commit 648b804 into Eventual-Inc:main Oct 7, 2024
36 checks passed
@desmondcheongzx desmondcheongzx deleted the fix-parquet2-arrow2-io-errors branch October 8, 2024 00:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants