Skip to content

gh-50393: "Clear and restart" IDLE shell windows#21682

Open
ZackerySpytz wants to merge 1 commit intopython:mainfrom
ZackerySpytz:bpo-6143-IDLE-clear-restart
Open

gh-50393: "Clear and restart" IDLE shell windows#21682
ZackerySpytz wants to merge 1 commit intopython:mainfrom
ZackerySpytz:bpo-6143-IDLE-clear-restart

Conversation

@ZackerySpytz
Copy link
Copy Markdown
Contributor

@ZackerySpytz ZackerySpytz commented Jul 30, 2020

Add a "Clear and Restart" item to the "Shell" menu. This can be used
to clear the contents of the shell window.

https://bugs.python.org/issue6143

Add a "Clear and Restart" item to the "Shell" menu.  This can be used
to clear the contents of the shell window.
Copy link
Copy Markdown
Member

@terryjreedy terryjreedy left a comment

Choose a reason for hiding this comment

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

I want a clear specification of the feature on the issue before reviewing further.

Tests are needed. Use Tal's as a start.

Comment thread Lib/idlelib/help.html
</dd>
<dt>Restart Shell</dt><dd><p>Restart the shell to clean the environment.</p>
</dd>
<dt>Clear and Restart</dt><dd><p>Restart the shell and clear the contents of the shell window.</p>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This file is generated from the IDLE doc: Doc/librarary/idle.rst. Edit latter instead.

Comment thread Lib/idlelib/pyshell.py
console.text.mark_unset("iomark")
console.text.delete("0.0", "end")
console.resetoutput()
console.write_header()
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I am not sure we need this. And the new function.

Comment thread Lib/idlelib/mainmenu.py
('shell', [
('_View Last Restart', '<<view-restart>>'),
('_Restart Shell', '<<restart-shell>>'),
('_Clear and Restart', '<<clear-restart-shell>>'),
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think Clear shell might be sufficient.

@bedevere-bot
Copy link
Copy Markdown

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@hauntsaninja hauntsaninja changed the title bpo-6143: "Clear and restart" IDLE shell windows gh-50393: "Clear and restart" IDLE shell windows Jan 7, 2023
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 8, 2026

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 Apr 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting changes stale Stale PR or inactive for long period of time.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants