Skip to content

gh-158955: PyREPL Update changed line planning for WSL - #158995

Merged
pablogsal merged 6 commits into
python:mainfrom
edvilme:pyrepl-wsl-insert-char
Nov 26, 2026
Merged

pablogsal merged 6 commits into
python:mainfrom
edvilme:pyrepl-wsl-insert-char

Conversation

@edvilme

@edvilme edvilme commented Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

PyREPL treated every single-character addition as an insertion, emitting the terminal’s ICH/INS control sequence before writing the character. On WSL, emitting INS at the end of a line could disturb terminal rendering and leave the displayed prompt/cursor out of sync.

This change uses a normal character write when appending at the end of the line, while preserving INS for true mid-line insertions.

Example: typing e after nam| now directly produces name|. INS remains used when inserting into nme to produce name.

@edvilme
edvilme marked this pull request as ready for review October 8, 2026 00:15
@pablogsal pablogsal added the needs backport to 3.15 bugs and security fixes label Nov 26, 2026
@pablogsal
pablogsal merged commit bd874ac into python:main Nov 26, 2026
63 checks passed
@miss-islington-app

Copy link
Copy Markdown

Thanks @edvilme for the PR, and @pablogsal for merging it 🌮🎉.. I'm working now to backport this PR to: 3.15.
🐍🍒⛏🤖

@bedevere-app

bedevere-app Bot commented Nov 26, 2026

Copy link
Copy Markdown

GH-162675 is a backport of this pull request to the 3.15 branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants