◐ Shell
reader mode source ↗
Skip to content

gh-71136: IDLE: Fix hanging when raise KeyboardInterrupt with debugger open#1711

Open
mlouielu wants to merge 3 commits into
python:mainfrom
mlouielu:bpo-26949-keyboardinterrupt
Open

gh-71136: IDLE: Fix hanging when raise KeyboardInterrupt with debugger open#1711
mlouielu wants to merge 3 commits into
python:mainfrom
mlouielu:bpo-26949-keyboardinterrupt

Conversation

@mlouielu

@mlouielu mlouielu commented May 22, 2017

Copy link
Copy Markdown
Contributor

When catch KeyboardInterrupt, it should put a dummy msg back to response_queue to prevent queue.Empty cause the infinity loop.

https://bugs.python.org/issue26949

@mention-bot

Copy link
Copy Markdown

@mlouielu, thanks for your PR! By analyzing the history of the files in this pull request, we identified @kbkaiser, @terryjreedy and @asvetlov to be potential reviewers.

@github-actions

Copy link
Copy Markdown

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label May 12, 2022
@hauntsaninja hauntsaninja changed the title bpo-26949: IDLE: Fix hanging when raise KeyboardInterrupt with debugger open Jan 7, 2023
@github-actions github-actions Bot removed the Stale PR or inactive for long period of time. label Jan 8, 2023
@github-actions

github-actions Bot commented Feb 7, 2023

Copy link
Copy Markdown

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Feb 7, 2023

@auvipy auvipy left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hide comment

I'm not sure, should we rework on this or close this completely?

@github-actions github-actions Bot removed the stale Stale PR or inactive for long period of time. label Feb 13, 2025
@github-actions

Copy link
Copy Markdown

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Mar 15, 2025
@github-actions github-actions Bot removed the stale Stale PR or inactive for long period of time. label Sep 5, 2025
@github-actions

github-actions Bot commented Oct 6, 2025

Copy link
Copy Markdown

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Oct 6, 2025
@github-actions github-actions Bot removed the stale Stale PR or inactive for long period of time. label Nov 10, 2025
@josephholsten

josephholsten commented Nov 10, 2025

Copy link
Copy Markdown
Contributor

My results are:

The reproduce step can be reduce to:

1. open idlelib with debugger (./python -m idlelib -d)
2. enter print() (or any other function call)
3. Control-C breakout

Then it will restart the shell.

Yields:

Python 3.14.0 (main, Oct  7 2025, 09:34:52) [Clang 17.0.0 (clang-1700.0.13.3)] on darwin
Enter "help" below or click "Help" above for more information.
[DEBUG ON]
print()

================================ RESTART: Shell ================================
[DEBUG ON]

@github-actions

Copy link
Copy Markdown

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Dec 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting core review stale Stale PR or inactive for long period of time. topic-IDLE

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants