From 58b56875e77be6c2b6b65bbec7300a16c6fd5573 Mon Sep 17 00:00:00 2001 From: Jeff Forcier Date: Fri, 11 Mar 2022 11:36:52 -0500 Subject: Clarify SFTPClient.open() docs re: actual behavior of BufferedFile Closes #2000 --- paramiko/sftp_client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/paramiko/sftp_client.py b/paramiko/sftp_client.py index 6294fb48..d6c3a70d 100644 --- a/paramiko/sftp_client.py +++ b/paramiko/sftp_client.py @@ -344,13 +344,13 @@ class SFTPClient(BaseSFTP, ClosingContextManager): ``O_EXCL`` flag in posix. The file will be buffered in standard Python style by default, but - can be altered with the ``bufsize`` parameter. ``0`` turns off + can be altered with the ``bufsize`` parameter. ``<=0`` turns off buffering, ``1`` uses line buffering, and any number greater than 1 (``>1``) uses that specific buffer size. :param str filename: name of the file to open :param str mode: mode (Python-style) to open in - :param int bufsize: desired buffering (-1 = default buffer size) + :param int bufsize: desired buffering (default: ``-1``) :return: an `.SFTPFile` object representing the open file :raises: ``IOError`` -- if the file could not be opened. -- cgit v1.2.1