[3.13] gh-151596: Add missing argument 'size' to pure-Python implementation of TextIOBase.readline (GH-151679) (GH-151872)

(cherry picked from commit 30aeeb375b)

Co-authored-by: saber-bit <bryanventura0324@gmail.com>
This commit is contained in:
Miss Islington (bot) 2026-06-23 18:41:37 +02:00 committed by GitHub
parent abf5016b4d
commit 0ba3fcdf2f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

View file

@ -1856,7 +1856,7 @@ def truncate(self, pos=None):
"""Truncate size to pos, where pos is an int."""
self._unsupported("truncate")
def readline(self):
def readline(self, size=-1, /):
"""Read until newline or EOF.
Returns an empty string if EOF is hit immediately.

View file

@ -0,0 +1 @@
Add missing ``size`` positional argument to the pure-Python implementation of :meth:`io.TextIOBase.readline`.