Skip to content

New Python REPL double-prints completion suggestions#127073

@ucodery

Description

@ucodery

Bug report

Bug description:

If a keyboard interrupt is given while TAB autocomplete suggestions are being displayed, they are re-printed also below the last line, and continue to be re-printed as long as new keyboard interrupts are given.

after the keystrokes int.<TAB><TAB>

int.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>int.

then <CTRL-C>

int.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>int. KeyboardInterruptint.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>

another <CTRL-C>

int.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>int. KeyboardInterruptint.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>KeyboardInterruptint.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>

<ENTER> makes the last set of printed suggestions disappear, as does typing any printing characters.

int.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>int. KeyboardInterruptint.as_integer_ratio( int.bit_length( int.denominatorint.imagint.mro() int.realint.bit_count( int.conjugate( int.from_bytes( int.is_integer( int.numeratorint.to_bytes( >>>KeyboardInterrupt>>>>>>

CPython versions tested on:

3.14

Operating systems tested on:

macOS

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibStandard 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