Skip to content

REPL feature: Re-print prompt when resumed #155432

Description

@schuelermine

Feature or enhancement

Proposal:

Currently, the Python REPL does not re-print the prompt after it is resumed after being suspended after the SUSP character is typed on the terminal.
The Python process needs to add a handler for the SIGCONT signal that re-prints the prompt.
Otherwise, a resumed Python REPL process looks broken:

Image

Has this already been discussed elsewhere?

This is a minor feature, which does not need previous discussion elsewhere

Links to previous discussion of this feature:

No response

Linked PRs

Activity

  1. added
    stdlibStandard Library Python modules in the Lib/ directory
    topic-replRelated to the interactive shell
    on Aug 9, 2026
  2. picnixz commented on Aug 9, 2026

    @picnixz
    Member

    Does it happen with the basic repl? (use PYTHON_BASIC_REPL=1 python)

  3. schuelermine commented on Aug 9, 2026

    @schuelermine
    Author

    @picnixz Yes, it does happen in the basic REPL. It also happens in older Python versions, before the fancy REPL was introduced.

    Image
  4. skirpichev commented on Aug 9, 2026

    @skirpichev
    Member

    BTW, this seems to be fixed in IPython:

    sk@note:~ $ ipython
    
    In [1]: 123
    Out[1]: 123
    
    
    [1]+  Stopped                 ipython
    sk@note:~ $ fg
    ipython
    In [2]: 
    
  5. edvilme commented on Aug 10, 2026

    @edvilme
    Contributor

    If you're not planning on, would love to take a look and propose a PR. Let me know if you are @schuelermine :)

  6. schuelermine commented on Aug 10, 2026

    @schuelermine
    Author

    I’m not familiar with the PyREPL codebase so it’s probably better if someone other than me takes a look, @edvilme

  7. added 2 commits that reference this issue on Aug 13, 2026
  8. added a commit that references this issue on Oct 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibStandard Library Python modules in the Lib/ directorytopic-replRelated to the interactive shelltype-featureA feature request or enhancement

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions