Skip to content

Comments

fix(bindings/python): Fix Writer doesn't throw correct error code#6315

Merged
Xuanwo merged 1 commit intomainfrom
improve-python-errors
Jun 19, 2025
Merged

fix(bindings/python): Fix Writer doesn't throw correct error code#6315
Xuanwo merged 1 commit intomainfrom
improve-python-errors

Conversation

@Xuanwo
Copy link
Member

@Xuanwo Xuanwo commented Jun 19, 2025

Which issue does this PR close?

Closes #6235

Rationale for this change

python bindings users FuturesWriter directly which returns rust IO error. This can lead to we return different exceptions compared to write.

What changes are included in this PR?

This PR fixed this by downcast them to the correct error.

Are there any user-facing changes?

No.

@Xuanwo Xuanwo requested review from Zheaoli and messense as code owners June 19, 2025 07:04
@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. releases-note/fix The PR fixes a bug or has a title that begins with "fix" labels Jun 19, 2025
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Jun 19, 2025
@Xuanwo Xuanwo merged commit c70b287 into main Jun 19, 2025
71 checks passed
@Xuanwo Xuanwo deleted the improve-python-errors branch June 19, 2025 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm This PR has been approved by a maintainer releases-note/fix The PR fixes a bug or has a title that begins with "fix" size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug(bindings/python): Python bindings can throw different error types for the same error code

3 participants