[MINOR][PYTHON] Remove deprecated use of typing.io#41084
Closed
hauntsaninja wants to merge 1 commit into
Closed
Conversation
Member
|
@hauntsaninja mind creating a JIRA, and keeping the PR description template (https://github.com/apache/spark/blob/master/.github/PULL_REQUEST_TEMPLATE)? See also https://spark.apache.org/contributing.html |
Contributor
Author
|
Thanks, I updated the PR to keep the template. Do I need to have a JIRA? The issue here is trivial / I don't have an account / my previous PR to Spark didn't need a JIRA (#29264) |
HyukjinKwon
approved these changes
May 8, 2023
Member
|
Merged to master. |
LuciferYang
pushed a commit
to LuciferYang/spark
that referenced
this pull request
May 10, 2023
### What changes were proposed in this pull request? Use `typing.BinaryIO` instead of `typing.io.BinaryIO`. The latter is deprecated and had questionable type checker support, see python/cpython#92871 ### Why are the changes needed? So Spark is unaffected when `typing.io` is removed in Python 3.13 ### Does this PR introduce any user-facing change? No ### How was this patch tested? Existing unit tests / every import of this module Closes apache#41084 from hauntsaninja/patch-1. Authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com> Signed-off-by: Hyukjin Kwon <gurwls223@apache.org>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
Use
typing.BinaryIOinstead oftyping.io.BinaryIO. The latter is deprecated and had questionable type checker support, see python/cpython#92871Why are the changes needed?
So Spark is unaffected when
typing.iois removed in Python 3.13Does this PR introduce any user-facing change?
No
How was this patch tested?
Existing unit tests / every import of this module