From: Bob Halley Date: Tue, 9 Jun 2020 14:08:13 +0000 (-0700) Subject: imnprove comment X-Git-Tag: v2.0.0rc1~114 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fa1d4938a8296b4ae88f7bbc5dfa67377995b9e2;p=thirdparty%2Fdnspython.git imnprove comment --- diff --git a/dns/trio/query.py b/dns/trio/query.py index 53b8fe50..a3a28fed 100644 --- a/dns/trio/query.py +++ b/dns/trio/query.py @@ -324,8 +324,9 @@ async def stream(q, where, tls=False, port=None, source=None, source_port=0, else: port = 53 wire = q.to_wire() - # We'd like to be able to use an AsyncExitStack here, but that's a 3.7 - # feature, so we are forced to try ... finally. + # We'd like to be able to use an AsyncExitStack here, because + # unlike closing a socket, closing a stream requires an await, but + # that's a 3.7 feature, so we are forced to try ... finally. sock = None s = None begin_time = time.time()