-
-
Notifications
You must be signed in to change notification settings - Fork 31.4k
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
Remove misleading sentence #11216
Remove misleading sentence #11216
Conversation
The sentence, “It inherits BufferedReader and BufferedWriter, and further supports seek() and tell() functionality,” is misleading: it suggests that BufferedRandom is special in that it is seekable, whereas BufferedReader and BufferedWriter are not. However, this is not the case: assuming the underlying raw stream is seekable (which is equally a requirement of BufferedRandom), then BufferedReader and BufferedWriter *are* seekable. Remove the misleading sentence.
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.
I think we still need to say something about seek
& tell
otherwise it's not clear what BufferedRandom
is for at all unless you know what a "random" stream is. We could say seek
and tell
must be supported.
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
For BufferedReader and BufferedWriter, seek and tell operations are optional (they may or may not exist based on the underlying stream). For BufferedRandom, they are mandatory: a BufferedRandom should not be constructed over an unseekable underlying stream. Document this.
How about this? I have made the requested changes; please review again. |
Thanks for making the requested changes! @benjaminp: please review the changes made to this pull request. |
Thanks @Hawk777 for the PR, and @benjaminp for merging it 🌮🎉.. I'm working now to backport this PR to: 2.7, 3.7. |
Thank you for the PR. |
The sentence, “It inherits BufferedReader and BufferedWriter, and
further supports seek() and tell() functionality,” is misleading: it
suggests that BufferedRandom is special in that it is seekable, whereas
BufferedReader and BufferedWriter are not. However, this is not the
case: assuming the underlying raw stream is seekable (which is equally a
requirement of BufferedRandom), then BufferedReader and BufferedWriter
are seekable. Remove the misleading sentence.