GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gh-75710: IDLE: Add tests to some editor.py functions by csabella · Pull Request #3669 · python/cpython

Conversation

@csabella

@csabella csabella commented Sep 20, 2017 •
edited by bedevere-bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Add docstrings and test for editor.py functions related to the reload from configdialog, creating the menubar, and applying keybindings.

https://bugs.python.org/issue31529

  • Issue: IDLE: Add docstrings and tests for editor.py reload functions #75710

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
csabella added 2 commits September 20, 2017 08:57
@csabella
IDLE: Add docstrings and tests for editor.py
c21d679
@csabella
Add blurb
d047c39
@the-knights-who-say-ni the-knights-who-say-ni added the CLA signed label Sep 20, 2017
@bedevere-bot bedevere-bot added the awaiting review label Sep 20, 2017
@csabella

csabella commented Sep 20, 2017 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

I was trying to understand the editor functions accessed from configdialog so that I could test those and thought the best way to understand what was really happening was to document and test the functions being called.

Some notes:

  1. I haven't done ResetColorizer because that seemed like its own rabbithole.
  2. I had to add a windows-only test because os.startfile is a windows only function and wouldn't work on my system. Hope it works.
  3. I was getting the timer_event CodeContext errors when running the tests, so I added a line to _close() in editor.py to unbind that event before deleting the text instance and it made the error go away. If it's the right fix, you may want to pull that out into its own PR.

Sorry that this is still massive. I really tried to limit it to what I needed to look at.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

terryjreedy
terryjreedy reviewed Sep 21, 2017
View reviewed changes
Comment thread Lib/idlelib/idle_test/test_editor.py Outdated
@@ -1,14 +1,432 @@
""" Test idlelib.editor.
"""

@terryjreedy terryjreedy Sep 21, 2017

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I will add a coverage line so we know how far we yet have to go.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I later did, which is part of the merge conflict.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Done, part of the merge conflict.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@csabella csabella mentioned this pull request Jan 20, 2019
gh-79951: IDLE - Convert menudefs to dictionary #11615
Closed
taleinat
taleinat reviewed Aug 9, 2019
View reviewed changes

@taleinat taleinat left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Amazing work adding so many tests for the editor window! I think these are sorely needed, and it's too bad they've been languishing here for a while now.

I've got a bunch of review comments, but overall this is a huge improvement, and I'd like to help get it through!

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated

This should be called before the keybindings are applied
in ApplyKeyBindings() otherwise the old bindings will still exist.
Note: this does not remove the Tk/Tcl keybindings attached to

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Add another blank line before the "Note:".

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Or leave out 'Note:'. I am going to revise these added docstrings.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py
def createmenubar(self):
"""Populate the menu bar widget for the editor window.

Each option on the menubar is itself a cascade-type Menu widget

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

IMO in this case, the rest of the doc-string after the first line should be a comment instead, since it describes the method's code rather than it's purpose.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

The problem goes deeper. There should be separate window-with-menu, frame, and text classes, and possibly an IDLE-menu class with a docstring that explains the menu system. And it maybe should be in mainmenu.py.

At present, the menu functions are scattered around this file. Right now, they should be at least gathered together in one section with one class-level block comment. Or maybe the added comment should be in mainmenu.py. This should be a separate PR.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
self.apply_bindings(xkeydefs)
#update menu accelerators
# Update menu accelerators.
# XXX - split into its own function and call it from here?

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Personally, I don't like adding such comments to the code.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Such comments should have initials and at least a year. But yes, they can hang around for decades. In this case I agree, as a separate method is needed to group together menu methods. Understanding this code requires knowing the menu term definitions.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
"Update the additional help entries on the Help menu"
"""Update the additional help entries on the Help menu.

First the existing additional help entries are removed from

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

In this doc-string, I find the added description of how the method works entirely unnecessary, because it is already similarly detailed in comments.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Agreed.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
"Create a callback with the helpfile value frozen at definition time"
"""Create a callback with the helpfile value frozen at definition time.

Args:

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

This style of describing args in doc-strings is non-standard. I think it would be shorter and simpler to just remove the "Args:" heading, and change the "Returns:" section into a single line of text.

Likewise for other methods.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Agreed. Cheryl did this PR after we refactored configdialog. For that, we had some exceptionally wordy docstrings to keep things clear. This docstring should start with 'Return...'

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
if self.color:
self.color.close(False)
self.color = None
# Allow code context to close its text.after calls.

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

How does unbinding the event allow the code context to do anything?

Also this is surprising to find given the title of this PR. If kept, it should be mentioned in the description and in the final commit message as an additional fix.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Agreed that revising _close, which has been somewhat problematical, is a separate issue.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
Args:
menudefs: Menu and submenu names, underlines (shortcuts),
and events which is a list of tuples of the form:
[(menu1, [(submenu1a, '<<virtual event>>'),

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Shouldn't the menu and sub-menu names in the examples be stings?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

This should not be here. See previous comment about explaining menu terms once.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/idle_test/test_editor.py

def setUpModule():
global root, editwin
requires('gui')

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Isn't it overly restrictive to require a GUI for all tests here? As an extreme example, testing prepstr() certainly doesn't require a GUI.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Agreed. I might be tempted to have separate test_editor_gui and test_editor_nogui files if not for the problem of coverage measurement. In any case, refactoring could isolate non-gui code for easier testing.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/idle_test/test_editor.py
eq(w.menudict['file'].entrycget(3, 'label'), 'Recent Files')
# No items added to helpmenu, so the length has no value.
eq(w.base_helpmenu_length, None)
w.fill_menus.assert_called_with()

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

If see this assertion and the next one as testing the implementation rather the behavior, so I suggest removing them.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I will check whether these should merely be deleted or replace with a behavior test.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/idle_test/test_editor.py
# EditorWindow that create the menubar and submenus.
# The class is mocked in order to prevent the functions
# from being called automatically.
w = cls.mock_editwin = mock.Mock(editor.EditorWindow)

@taleinat taleinat Aug 9, 2019

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Do I understand correctly that this uses a mock mostly to avoid all of the setup in EditorWindow.init()? That could also be accomplished by patching that method (e.g. with mock.patch) or by creating a sub-class.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

We have elsewhere used a standalone class. In this case, a subclass would inherit menu_spec. I will look at how w is used.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@taleinat

taleinat commented Sep 20, 2020

Copy link
Copy Markdown
Contributor

Ping, @csabella?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

terryjreedy
terryjreedy requested changes Sep 21, 2020
View reviewed changes

@terryjreedy terryjreedy left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I am going to first edit the new docstrings as indicated in my reponses to Tal's comments, and make a separate PR.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py
def createmenubar(self):
"""Populate the menu bar widget for the editor window.

Each option on the menubar is itself a cascade-type Menu widget

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

The problem goes deeper. There should be separate window-with-menu, frame, and text classes, and possibly an IDLE-menu class with a docstring that explains the menu system. And it maybe should be in mainmenu.py.

At present, the menu functions are scattered around this file. Right now, they should be at least gathered together in one section with one class-level block comment. Or maybe the added comment should be in mainmenu.py. This should be a separate PR.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated

This should be called before the keybindings are applied
in ApplyKeyBindings() otherwise the old bindings will still exist.
Note: this does not remove the Tk/Tcl keybindings attached to

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Or leave out 'Note:'. I am going to revise these added docstrings.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
self.apply_bindings(xkeydefs)
#update menu accelerators
# Update menu accelerators.
# XXX - split into its own function and call it from here?

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Such comments should have initials and at least a year. But yes, they can hang around for decades. In this case I agree, as a separate method is needed to group together menu methods. Understanding this code requires knowing the menu term definitions.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
"Update the additional help entries on the Help menu"
"""Update the additional help entries on the Help menu.

First the existing additional help entries are removed from

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Agreed.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py Outdated
"Create a callback with the helpfile value frozen at definition time"
"""Create a callback with the helpfile value frozen at definition time.

Args:

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Agreed. Cheryl did this PR after we refactored configdialog. For that, we had some exceptionally wordy docstrings to keep things clear. This docstring should start with 'Return...'

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/editor.py
s = re.sub(r"-[a-z]\b", lambda m: m.group().upper(), s)
# Convert certain keynames to their symbol.
s = re.sub(r"\b\w+\b", lambda m: keynames.get(m.group(), m.group()), s)
# Remove Key- from string.

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

The first 2 added comments are helpful, the rest are obvious.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/idle_test/test_editor.py Outdated
@@ -1,14 +1,432 @@
""" Test idlelib.editor.
"""

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Done, part of the merge conflict.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/idle_test/test_editor.py

def setUpModule():
global root, editwin
requires('gui')

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Agreed. I might be tempted to have separate test_editor_gui and test_editor_nogui files if not for the problem of coverage measurement. In any case, refactoring could isolate non-gui code for easier testing.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/idle_test/test_editor.py
# EditorWindow that create the menubar and submenus.
# The class is mocked in order to prevent the functions
# from being called automatically.
w = cls.mock_editwin = mock.Mock(editor.EditorWindow)

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

We have elsewhere used a standalone class. In this case, a subclass would inherit menu_spec. I will look at how w is used.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread Lib/idlelib/idle_test/test_editor.py
eq(w.menudict['file'].entrycget(3, 'label'), 'Recent Files')
# No items added to helpmenu, so the length has no value.
eq(w.base_helpmenu_length, None)
w.fill_menus.assert_called_with()

@terryjreedy terryjreedy Sep 20, 2020

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I will check whether these should merely be deleted or replace with a behavior test.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@bedevere-bot bedevere-bot added awaiting changes and removed awaiting review labels Sep 21, 2020
@bedevere-bot

bedevere-bot commented Sep 21, 2020

Copy link
Copy Markdown

When you're done making the requested changes, leave the comment: I have made the requested changes; please review again.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@terryjreedy

terryjreedy commented Sep 21, 2020

Copy link
Copy Markdown
Member

Whoops, by responding to Tal's comments as part of a new review, my responses got listed twice, once under Tal's comment where they below and then again separately, without the context.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@terryjreedy
Merge branch 'master' into binding_tests
435ea82
@terryjreedy

terryjreedy commented Sep 21, 2020

Copy link
Copy Markdown
Member

I minimally resolved the merge conflict in the web box so I could proceed. This did a full merge update rather than just updating the one file. There is still the redundancy of global requires gui and class requires gui to be fixed, and Tal's other conflicts. Since I had to do this, I will go ahead and edit everything on this PR.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

terryjreedy added 3 commits September 20, 2020 21:13
@terryjreedy
Synchronize tkinter import in test_editor
ac8dae4
@terryjreedy
Update test_editor.py
eb25140
More tk. prefixes.
@terryjreedy
Remove test of removed _filename_to_unicode method.
8dfbd49
@terryjreedy

terryjreedy commented Sep 21, 2020 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

I stopped the Windows test failures by commenting out the failing lines with an explanation.

The Ubuntu failure is

  File "/home/runner/work/cpython/cpython-ro-srcdir/Lib/idlelib/idle_test/test_editor.py", line 422, in test__extra_help_callback_not_windows
    ehc = partial(w._EditorWindow__extra_help_callback, w)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...
AttributeError: Mock object has no attribute '_EditorWindow__extra_help_callback'. Did you mean: '_EditorWindow__recent_file_callback'?

May do the same here.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

terryjreedy added 3 commits September 20, 2020 23:44
@terryjreedy
Remove unneeded extra underscore.
0308f80
@terryjreedy
Make test pass; delete redundant asserts.
c32379b
@terryjreedy
Docstring and comment and a couple code revisions.
ba274a4
@terryjreedy

terryjreedy commented Sep 21, 2020

Copy link
Copy Markdown
Member

I think editor.py is more or less commit ready. Tal, review again or not as you wish.

Test_editor is not ready. test_editor passes, but still needs requires('gui') restricted. I want to try Tal's suggested alternative. And also make sure that every test is actually testing. The test I revised was not, as the function supposedly being tested was mocked.

test_mainmenu passes by itself, but test_idle fails with

File "f:\dev\3x\lib\idlelib\idle_test\test_mainmenu.py", line 17, in test_default_keydefs
self.assertGreaterEqual(len(mainmenu.default_keydefs), 50)
AssertionError: 5 not greater than or equal to 50

5 happens to be the length of keydefs used in test_editor, which run first, so the test change is somehow affecting mainmenu. This is probably via changing something in config. test_editor does not import config, but editor does.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

terryjreedy added 2 commits January 25, 2021 07:37
@terryjreedy
Merge branch 'master' into binding_tests
b5d80cb
@terryjreedy
Merge remote-tracking branch 'upstream/master' into pr_3669
3fbf6da
@terryjreedy

terryjreedy commented Feb 20, 2021

Copy link
Copy Markdown
Member

Additional test failure: Windows error box titled "Document Start Failure" with message "(X) boom". Test freezes until box is dismissed. I suspect a test of additional help resources needs mocks for both Windows and *nix.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Feb 23, 2022
@ezio-melotti ezio-melotti removed the CLA signed label Jul 13, 2022
@github-actions github-actions Bot removed the stale Stale PR or inactive for long period of time. label Jul 29, 2022
@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Sep 1, 2022
@hauntsaninja hauntsaninja changed the title bpo-31529: IDLE: Add docstrings and tests to some editor.py functions gh-75710: IDLE: Add docstrings and tests to some editor.py functions Jan 7, 2023
@github-actions github-actions Bot removed the stale Stale PR or inactive for long period of time. label Jan 8, 2023
@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Feb 7, 2023
@terryjreedy
Merge remote-tracking branch 'upstream/main' into pr_3669
0aea634
@python python deleted a comment from github-actions Bot May 13, 2023
@python python deleted a comment from github-actions Bot May 13, 2023
@python python deleted a comment from github-actions Bot May 13, 2023
@terryjreedy
whitespace
cf8044e
terryjreedy added a commit to terryjreedy/cpython that referenced this pull request May 13, 2023
@terryjreedy @csabella
pythongh-75710: IDLE - add docstrings and comments to editor module
4d47692
Commit extracted from PR python#3669.  Will edits more later.

Co-authored-by: Cheryl Sabella <[email protected]>
@terryjreedy terryjreedy mentioned this pull request May 13, 2023
gh-75710: IDLE - add docstrings and comments to editor module #104446
Merged
@csabella csabella mentioned this pull request Jul 27, 2022
IDLE: Add docstrings and tests for editor.py reload functions #75710
Open
@terryjreedy
Merge branch 'main' into binding_tests
fba2ef2
terryjreedy added a commit that referenced this pull request May 13, 2023
@terryjreedy @csabella
gh-75710: IDLE - add docstrings and comments to editor module (#104446)
46f1c78
Commit extracted from PR #3669.  Will edit more later.

Co-authored-by: Cheryl Sabella <[email protected]>
@miss-islington miss-islington mentioned this pull request May 13, 2023
[3.11] gh-75710: IDLE - add docstrings and comments to editor module (GH-104446) #104450
Merged
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request May 13, 2023
@terryjreedy @csabella @miss-islington
pythongh-75710: IDLE - add docstrings and comments to editor module (p…
d9a5812
…ythonGH-104446)

Commit extracted from PR pythonGH-3669.  Will edit more later.

(cherry picked from commit 46f1c78)

Co-authored-by: Terry Jan Reedy <[email protected]>
Co-authored-by: Cheryl Sabella <[email protected]>
@terryjreedy
Merge branch 'main' into binding_tests
47ebc2d
terryjreedy added a commit that referenced this pull request May 13, 2023
@miss-islington @terryjreedy @csabella
[3.11] gh-75710: IDLE - add docstrings and comments to editor module (G…
b87ccc3
…H-104446) (#104450)

gh-75710: IDLE - add docstrings and comments to editor module (GH-104446)

Commit extracted from PR GH-3669.  Will edit more later.

(cherry picked from commit 46f1c78)

Co-authored-by: Terry Jan Reedy <[email protected]>
Co-authored-by: Cheryl Sabella <[email protected]>
@github-actions github-actions Bot removed the stale Stale PR or inactive for long period of time. label May 14, 2023
@github-actions

github-actions Bot commented Jun 14, 2023

Copy link
Copy Markdown

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

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@github-actions github-actions Bot added the stale Stale PR or inactive for long period of time. label Jun 14, 2023
@hugovk hugovk changed the title gh-75710: IDLE: Add docstrings and tests to some editor.py functions gh-75710: IDLE: Add tests to some editor.py functions Jan 9, 2025
@github-actions github-actions Bot removed the stale Stale PR or inactive for long period of time. label Jan 9, 2025
@github-actions

github-actions Bot commented Feb 8, 2025

Copy link
Copy Markdown

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

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

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

ambv commented Oct 21, 2026

Copy link
Copy Markdown
Contributor

This PR is blocked on its author, has not been touched by a human in more than 3 years, and no longer merges cleanly. Closing to cull the number of open pull requests. Do not reopen this pull request without getting a go-ahead from a triager or core developer on gh-75710.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ambv ambv closed this Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@terryjreedy terryjreedy terryjreedy requested changes
+1 more reviewer
@taleinat taleinat taleinat left review comments
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

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

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

7 participants

@csabella @taleinat @bedevere-bot @terryjreedy @ambv @the-knights-who-say-ni @ezio-melotti
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.