gh-115514: Fix incomplete writes after close in asyncio._SelectorSocketTransport by Tasssadar · Pull Request #128037 · python/cpython · GitHub

github.com

Tin mới

Tasssadar:fix-socket-writes

miss-islington-app

GitHub CopilotWrite better code with AI

GitHub Copilot appDirect agents from issue to merge

ActionsAutomate any workflow

CodespacesInstant dev environments

IssuesPlan and track work

Code ReviewManage code changes

Code QualityEnforce quality at merge

GitHub Advanced SecurityFind and fix vulnerabilities

Code securitySecure your code as you build

Secret protectionStop leaks before they start

View all use cases

Financial services

View all industries

Software Development

GitHub SponsorsFund open source developers

Copilot for BusinessEnterprise-grade AI features

Premium SupportEnterprise-grade 24/7 support

Pull requests 2.6k

Security and quality 0

Spurious "Exception in callback None()" after upgrading to 3.12 #115514

bedevere-app Bot commented Dec 17, 2024

bedevere-app Bot commented Dec 17, 2024

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

needs backport to 3.12

needs backport to 3.12

needs backport to 3.13

needs backport to 3.13

View reviewed changes

Learn more about hiding disruptive comments

The reason will be displayed to describe this comment to others. Learn more.

cpython/Lib/asyncio/selector_events.py

happens to be a more real-world-like test in SSL

Hi, could you please suggest on how to do that? The TestLoop used here does not process the writers when it is ran, so for example self.loop.run_until_complete(asyncio.sleep(0)) does not work.

Fix incomplete writes after close in asyncio._SelectorSocketTransport

Run cleanup in finally in _SelectorSocketTransport._call_connection_lost

chore: review tweaks

Make test_remote_shutdown_receives_trailing_data trigger

View reviewed changes

Split ssl test into another case, test_remote_shutdown_receives_trail…

awaiting change review

awaiting change review

Make ssl test work on Linux

View reviewed changes

Merge branch 'main' into fix-socket-writes

: Fix incomplete writes after close while using ssl in…

: Fix incomplete writes after close while using ssl in…

: Fix incomplete writes after close while using ssl i…

: Fix incomplete writes after close while using ssl i…

: Fix incomplete writes after close while using ssl in…

Automatic backup failed to upload to cloud exactly 45 minutes after backup was created, then filled logs with job exceptions home-assistant/core#134082

Update Home Assistant base image to 2025.02.1 home-assistant/core#138746

redis/redis-py#3546

That would be redis/redis-py#3546, not a CPython problem.

asyncio: _call_connection_lost() is called twice when resume_writing() closes the transport #156512