Terry J. Reedy added the comment:

Thank you for doing the research.  It seems that extensions are the only 
unknown. Steps for doing this.

1. Nick once said to start with a notice in idlelib.__init__.  How about the 
following.

The idlelib package implements the Idle application, which include an 
interactive shell and editor.  The files named idle.* should be used to start 
Idle.  The other files are private implementations and should not be imported 
by other applications. Their details are subject to change. See PEP 434  for 
more informaton.

2. Put same in NEWS.txt -- not just a notice that a notice was added to 
.__init__, but the notice itself.

3. Put a single line at the top of each 'new' file. Perhaps

# Private implementation module. API subject to change.

4. 'Old' files, which will go away someday, perhaps as soon as 3.6, are less of 
a concern to me.  If one that has been replaced by a ttk version is imported 
when use_ttk is true, we can assume that it is being imported by an extension 
and issue a DeprecationWarning.

5. PyShell is a special case since "from idlelib.PyShell import main; main()" 
(essentially the content of idlelib.__main__) was once advertised as the way to 
start Idle. PyShell is also a special case because it includes startup code, 
shell code, and editor debug code, making it a prime target for refactoring. If 
main() were moved elsewhere and __main__.py and idle.* files modified to point 
to the new location, we could raise a DeprecationWarning in PyShell.main before 
calling the new main.

----------
assignee:  -> terry.reedy
priority: normal -> high
versions: +Python 2.7, Python 3.4

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue24861>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to