python / python/cpython

Python3.15.0a1 REPL : issue with pasting of Tab indented multiline code

Open
#140,502 15 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

3.14 3.15 stdlib topic-repl type-bug
Dominant language
Python
Stars
77.2k
Forks
35.9k
PR merge metrics
PR metrics pending

Description

Bug report

Bug description:

Misaligned output of pasted Tab-indented multiline code into the REPL:

~ $ python3.13
Python 3.13.8 (main, Oct 15 2025, 02:41:02) [GCC 11.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from PyQt6.QtWidgets import QApplication, QWidget
... from PyQt6.QtGui import QPainter, QColor, QPen
... from PyQt6.QtCore import Qt, QRect
... from cv2 import (
...     cvtColor,
...         COLOR_Lab2RGB,
...         COLOR_HSV2RGB_FULL,
...         COLOR_HLS2RGB_FULL,
... 
...         COLOR_RGB2Lab,
...         COLOR_RGB2HSV_FULL,
...         COLOR_RGB2HLS_FULL,
... 
... )
... 
>>> exit
~ $ python3.15
Python 3.15.0a1 (main, Oct 17 2025, 14:09:27) [GCC 11.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from PyQt6.QtWidgets import QApplication, QWidget
... from PyQt6.QtGui import QPainter, QColor, QPen
... from PyQt6.QtCore import Qt, QRect
... from cv2 import (
... 	cvtColor							,
                                                    ... 		COLOR_Lab2RGB				,
                                                                                         ... 		COLOR_HSV2RGB_FULL			,
... 		COLOR_HLS2RGB_FULL			,
                             ... 
                             ... 		COLOR_RGB2Lab				,
                                                                 ... 		COLOR_RGB2HSV_FULL			,
                                                                                           ... 		COLOR_RGB2HLS_FU... )			,
... 
>>> exit
~ $ 
CPython versions tested on:

3.15

Operating systems tested on:

Linux

Linked PRs
  • gh-140697

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the shown Tab-indented multiline paste in the Python 3.15 REPL on Linux and compare its output with Python 3.13. The fix is complete when pasted multiline code remains correctly aligned instead of gaining large spacing offsets; the issue references linked PR gh-140697.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.