Skip to content

REPL pasting behavior is different on Windows and unix consoles #148861

@GabrielvMarinho

Description

@GabrielvMarinho

Bug report

Bug description:

Pasting multiline content on the unix console looks like this:
https://github.com/user-attachments/assets/b3813ab6-08bf-4d30-8f43-c52eb779e805
Which feels like the right behavior.

Windows on the other hand looks like this:
https://github.com/user-attachments/assets/354cae9f-6b51-4b15-be8c-a78cf7a90e50

I think this can be quite confusing and it doesn't let you edit the content before actually interpreting it, like the unix console lets you.

For this reason I think it would be good to patch the windows version to behavior the same as the unix one.

CPython versions tested on:

3.15, CPython main branch

Operating systems tested on:

Windows

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    OS-windowsstdlibStandard Library Python modules in the Lib/ directorytopic-replRelated to the interactive shelltype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions