Title: Class Browser doesn't show internal classes
Type: enhancement Stage: test needed
Components: IDLE Versions: Python 3.6, Python 3.5, Python 2.7
Status: open Resolution:
Dependencies: 6691 Superseder:
Assigned To: Nosy List: ajaksu2, gpolo, roger.serwy, terry.reedy
Priority: normal Keywords: patch

Created on 2006-12-09 17:38 by taleinat, last changed 2015-09-14 02:29 by terry.reedy.

File name Uploaded Description Edit
classbrowser_nesting_support.diff gpolo, 2009-08-12 22:51 review
Messages (6)
msg30777 - (view) Author: Tal Einat (taleinat) * (Python committer) Date: 2006-12-09 17:38
If I define a class within a class, like this:

class A:
    class B:
    def foo(self):

The class browser shows that A contains foo, but it doesn't show B at all.
msg84594 - (view) Author: Daniel Diniz (ajaksu2) Date: 2009-03-30 17:39
Confirmed on trunk and py3k.
msg89549 - (view) Author: Roger Serwy (roger.serwy) * (Python committer) Date: 2009-06-20 20:48
The class browser relies on the pyclbr module to scan the code. This
module doesn't support classes within classes. Both pyclbr and IDLE's
class browser need to be modified.
msg91499 - (view) Author: Guilherme Polo (gpolo) * (Python committer) Date: 2009-08-12 16:43
The attached patch adds support for nested objects in pyclbr and also in

I have yet to find an optimal way to test this on test_pyclbr (I did
some things here, none very nice), so you will notice tests are missing
on this patch.
msg91509 - (view) Author: Guilherme Polo (gpolo) * (Python committer) Date: 2009-08-12 22:51
I've removed the previous patch from here and attached an updated one on

Now the patch attached here only contains changes related to
msg250596 - (view) Author: Terry J. Reedy (terry.reedy) * (Python committer) Date: 2015-09-14 02:29
Class Browser is now a module browser as it includes functions not in classes. I guess pyclbr does this. Enhancing this for current versions would require adding a private copy of enhanced pyclbr to idlelib.
Date User Action Args
2015-09-14 02:29:36terry.reedysetpriority: low -> normal
versions: + Python 2.7, Python 3.5, Python 3.6, - Python 3.2
nosy: + terry.reedy

messages: + msg250596
2014-02-04 12:05:48taleinatsetnosy: - taleinat
2010-08-25 14:37:43BreamoreBoysetversions: + Python 3.2, - Python 3.1, Python 2.7
2009-08-12 22:51:23gpolosetfiles: - show_nested_objects.diff
2009-08-12 22:51:14gpolosetfiles: + classbrowser_nesting_support.diff

dependencies: + Support for nested classes and function for pyclbr
messages: + msg91509
2009-08-12 16:43:57gpolosetfiles: + show_nested_objects.diff

nosy: + gpolo
messages: + msg91499

keywords: + patch
2009-06-20 20:48:19roger.serwysetnosy: + roger.serwy
messages: + msg89549
2009-03-30 17:39:48ajaksu2setpriority: normal -> low

type: enhancement
versions: + Python 3.1, Python 2.7, - Python 2.6
nosy: + ajaksu2

messages: + msg84594
stage: test needed
2006-12-09 17:38:55taleinatcreate