https://github.com/python/cpython/commit/ac42dc48684ca0aeb8d458eab1c4c15600d7ebb1
commit: ac42dc48684ca0aeb8d458eab1c4c15600d7ebb1
branch: main
author: Pengyu Lee <[email protected]>
committer: kumaraditya303 <[email protected]>
date: 2026-10-19T13:27:25+05:30
summary:
gh-157418: Correct the ` IocpProactor.recvfrom_into()` parameter name (#157422)
files:
A Misc/NEWS.d/next/Windows/2026-09-14-16-49-44.gh-issue-157418.r2IggA.rst
M Lib/asyncio/windows_events.py
diff --git a/Lib/asyncio/windows_events.py b/Lib/asyncio/windows_events.py
index 2a7c18cda8a76a5..b17ac7ab255fc59 100644
--- a/Lib/asyncio/windows_events.py
+++ b/Lib/asyncio/windows_events.py
@@ -515,11 +515,11 @@ def recvfrom(self, conn, nbytes, flags=0):
return self._register(ov, conn, partial(self._finish_recvfrom,
empty_result=b''))
- def recvfrom_into(self, conn, buf, flags=0):
+ def recvfrom_into(self, conn, buf, nbytes=0):
self._register_with_iocp(conn)
ov = _overlapped.Overlapped(NULL)
try:
- ov.WSARecvFromInto(conn.fileno(), buf, flags)
+ ov.WSARecvFromInto(conn.fileno(), buf, nbytes)
except BrokenPipeError:
return self._result((0, None))
diff --git
a/Misc/NEWS.d/next/Windows/2026-09-14-16-49-44.gh-issue-157418.r2IggA.rst
b/Misc/NEWS.d/next/Windows/2026-09-14-16-49-44.gh-issue-157418.r2IggA.rst
new file mode 100644
index 000000000000000..b1a048c46ab83cc
--- /dev/null
+++ b/Misc/NEWS.d/next/Windows/2026-09-14-16-49-44.gh-issue-157418.r2IggA.rst
@@ -0,0 +1,3 @@
+Correct the third parameter name of ``IocpProactor.recvfrom_into()`` from
+*flags* to *nbytes* to reflect that it specifies the number of bytes to
+receive.
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]