diff options
author | Jeff Forcier <jeff@bitprophet.org> | 2017-11-07 09:34:21 -0800 |
---|---|---|
committer | Jeff Forcier <jeff@bitprophet.org> | 2017-11-07 09:34:21 -0800 |
commit | 11e46d109a19b2dc557ed2e31e3f3f8a16c726a9 (patch) | |
tree | 50423ee18c75ab4caf9c437d67b4446293030ae6 | |
parent | 71608fd6615ab88ab9ca5b3a8ad1e89a342afd58 (diff) | |
parent | a838d0e87afc094499705c4fe9623befcce2e822 (diff) |
Merge branch '2.1' into 2.2
-rw-r--r-- | paramiko/sftp_file.py | 8 | ||||
-rw-r--r-- | sites/www/changelog.rst | 3 |
2 files changed, 7 insertions, 4 deletions
diff --git a/paramiko/sftp_file.py b/paramiko/sftp_file.py index 028d894a..bc34db94 100644 --- a/paramiko/sftp_file.py +++ b/paramiko/sftp_file.py @@ -65,15 +65,15 @@ class SFTPFile (BufferedFile): self._reqs = deque() def __del__(self): - self._close(async=True) + self._close(async_=True) def close(self): """ Close the file. """ - self._close(async=False) + self._close(async_=False) - def _close(self, async=False): + def _close(self, async_=False): # We allow double-close without signaling an error, because real # Python file objects do. However, we must protect against actually # sending multiple CMD_CLOSE packets, because after we close our @@ -88,7 +88,7 @@ class SFTPFile (BufferedFile): self.sftp._finish_responses(self) BufferedFile.close(self) try: - if async: + if async_: # GC'd file handle could be called from an arbitrary thread # -- don't wait for a response self.sftp._async_request(type(None), CMD_CLOSE, self.handle) diff --git a/sites/www/changelog.rst b/sites/www/changelog.rst index fe08b9dd..cf77a812 100644 --- a/sites/www/changelog.rst +++ b/sites/www/changelog.rst @@ -2,6 +2,9 @@ Changelog ========= +* :bug:`1108 (1.17+)` Rename a private method keyword argument (which was named + ``async``) so that we're compatible with the upcoming Python 3.7 release + (where ``async`` is a new keyword.) Thanks to ``@vEpiphyte`` for the report. * :support:`- backported` Include LICENSE file in wheel archives. * :release:`2.2.2 <2017-09-18>` * :release:`2.1.4 <2017-09-18>` |