From 94ae8ffb36d0a7bbaf402573eff560da1997f84f Mon Sep 17 00:00:00 2001 From: Jeff Forcier Date: Mon, 25 Jul 2016 20:32:17 -0700 Subject: Give Channel ._closed as alias to .closed. Fixes #774. --- paramiko/channel.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/paramiko/channel.py b/paramiko/channel.py index 3c43eb10..3a05bdc4 100644 --- a/paramiko/channel.py +++ b/paramiko/channel.py @@ -887,6 +887,12 @@ class Channel (ClosingContextManager): """ self.shutdown(1) + @property + def _closed(self): + # Concession to Python 3's socket API, which has a private ._closed + # attribute instead of a semipublic .closed attribute. + return self.closed + ### calls from Transport def _set_transport(self, transport): -- cgit v1.2.3 From c0c0dffb8b5827c2cf449b5247cfe590ebd0f6df Mon Sep 17 00:00:00 2001 From: Jeff Forcier Date: Mon, 25 Jul 2016 20:33:54 -0700 Subject: Changelog closes #774 --- sites/www/changelog.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sites/www/changelog.rst b/sites/www/changelog.rst index a7cdeffd..6004a6e7 100644 --- a/sites/www/changelog.rst +++ b/sites/www/changelog.rst @@ -2,6 +2,10 @@ Changelog ========= +* :bug:`774 (1.16+)` Add a ``_closed`` private attribute to + `~paramiko.channel.Channel` objects so that they continue functioning when + used as proxy sockets under Python 3 (e.g. as ``direct-tcpip`` gateways for + other Paramiko connections.) * :bug:`758 (1.16+)` Apply type definitions to ``_winapi`` module from `jaraco.windows `_ 3.6.1. This should address issues on Windows platforms that often result in errors like -- cgit v1.2.3