[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-16 Thread STINNER Victor
STINNER Victor added the comment: > In modern asyncio code the explicit loop arguments are no longer used since > the loop can always be obtained with get_running_loop(). Yeah, the trend changed. Around Python 3.4, passing explicitly loop was preferred for best performances. Since that time,

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread Andrew Svetlov
Andrew Svetlov added the comment: Raymond, sorry if I was so quick in applying. The patch is very trivial and obvious. I am pretty sure that Yuri and Victor approve it. The PR doesn't fix a mistake, the code is still valid. But we all changed our mind what is the loop role, should it be explic

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread Hrvoje Nikšić
Hrvoje Nikšić added the comment: Raymond, no problem; I guess I assumed that the authors are following the bug tracker (or have possibly moved on and are inactive). I also had reason to believe the change to be non-controversial, since it is in line with Yury's own recommendations, e.g. from

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread Andrew Svetlov
Andrew Svetlov added the comment: Thanks Hrvoje! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread miss-islington
miss-islington added the comment: New changeset 1cd6e926d30552056457820a682c1c361ee0f3ff by Miss Islington (bot) in branch '3.8': bpo-38178: Don't explicitly pass "loop" to EchoClientProtocol. (GH-16159) https://github.com/python/cpython/commit/1cd6e926d30552056457820a682c1c361ee0f3ff -

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread Raymond Hettinger
Raymond Hettinger added the comment: Hrvoje, thanks for fixing this. Next time, please involve the people who originally wrote the code. They are both still active. If they made mistakes, it helps them to know about it. If they had a specific intent for the code example, it allows them to

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread miss-islington
miss-islington added the comment: New changeset 701c4886bb0e19ad5ed8c8f556f65ab8597841e7 by Miss Islington (bot) in branch '3.7': bpo-38178: Don't explicitly pass "loop" to EchoClientProtocol. (GH-16159) https://github.com/python/cpython/commit/701c4886bb0e19ad5ed8c8f556f65ab8597841e7 -

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread miss-islington
Change by miss-islington : -- pull_requests: +15772 pull_request: https://github.com/python/cpython/pull/16162 ___ Python tracker ___ __

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread miss-islington
Change by miss-islington : -- pull_requests: +15771 pull_request: https://github.com/python/cpython/pull/16161 ___ Python tracker ___ __

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread miss-islington
miss-islington added the comment: New changeset c717c73fa33a2f3591442059eaf6e7a673e2c725 by Miss Islington (bot) (Hrvoje Nikšić) in branch 'master': bpo-38178: Don't explicitly pass "loop" to EchoClientProtocol. (GH-16159) https://github.com/python/cpython/commit/c717c73fa33a2f3591442059eaf6e7

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread Raymond Hettinger
Raymond Hettinger added the comment: The was added originally by Victor and Yuri in c7edff3 and 7c7605ff113 -- nosy: +rhettinger, vstinner ___ Python tracker ___ _

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread Hrvoje Nikšić
Change by Hrvoje Nikšić : -- keywords: +patch pull_requests: +15769 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16159 ___ Python tracker ___ ___

[issue38178] Remove explicit "loop" argument from EchoClientProtocol example

2019-09-15 Thread Hrvoje Nikšić
New submission from Hrvoje Nikšić : The EchoClientProtocol example receives a "loop" argument, which is not used at all in the TCP example, and is used to create a future in the UDP example. In modern asyncio code the explicit loop arguments are no longer used since the loop can always be obta