Skip to content

Clarify behavior of socket.send/socket.recv on closed connection #145024

@bkap123

Description

@bkap123

Documentation

Building on Issue #109532 for the socket HOWTO guide, I think it would be worthwhile to emphasize in the docs for socket.send that, in contrast to socket.recv, an OSError is raised for a broken connection. This change will hopefully clarify when the caller is responsible for handling a broken connection, that is, when socket.recv returns 0.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation in the Doc dir

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions