This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: OS X IDLE.app and bin/idle: missing/extra menu options
Type: behavior Stage:
Components: IDLE, macOS Versions: Python 3.0, Python 3.1, Python 2.7, Python 2.6
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: ned.deily, ronaldoussoren
Priority: normal Keywords:

Created on 2009-02-10 02:55 by ned.deily, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
patch-nad0014-trunk-26.txt ned.deily, 2009-02-10 02:55
patch-nad0014-py3k-30.txt ned.deily, 2009-02-10 02:55
Messages (3)
msg81525 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2009-02-10 02:55
IDLE is supposed to have various menu customizations when running on OS 
X. But currently they do not all work and the menus vary if IDLE is 
launched via IDLE.app versus via command line bin/idle.  The most 
noticeable issue is the lack of a Preferences menu item in IDLE.app to 
access the IDLE configuration settings.

ANALYSIS    There are inconsistent OS X execution checks scattered
            throughout idlelib.  Also, the bootstrap mechanism
            for IDLE.app causes sys.executable to be set incorrectly.
            Most importantly, idlemain imports idlelib before it
            has fixed up the execution environment.  This can cause
            the menu fixup in idlelib.Bindings to be skipped.

SOLUTION    Change idlemain to set up the execution environment
            consistently and defer idlelib imports until it has done so.
            Modify several OS X checks in idlelib for consistency.

APPLIES     py3k, 3.0   -> patch-nad0014-py3k-30.txt
            trunk, 2.6  -> patch-nad0014-trunk-26.txt

DELETE      Mac/IDLE/idlemain.py    (py3k and 3.0 only!)

NOTE        In 3.x idlemain.py was copied down into the app bundle:
                2.x -> Mac/IDLE/idlemain.py
                3.x -> Mac/IDLE/IDLE.app/Contents/Resources/idlemain.py
                3.x -> Mac/IDLE/idlemain.py  -> unused / delete
            so there are two versions of this patch.
            However, the 2.x location was not deleted in 3.x svn
            so there are two identical files in 3.x prior to this
            patch.
msg81769 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2009-02-12 15:05
I've fixed this for 3.1 in r69532. Fixed for 3.0 in r69533 (backport of 
the other patch).

The actual checkin is based on "patch-nad0014-py3k-30.txt", but with some 
minor tweaks (I use "idlelib.macosxSupport.runningAsOSXApp" throughout, 
instead of sometimes doing the same check by hand).
msg83140 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2009-03-04 21:36
I've applied a cleaned up version of patch-nad0014-trunk-26.txt to the 
trunk and 2.6 branch. This completely fixes this issue.
History
Date User Action Args
2022-04-11 14:56:45adminsetgithub: 49444
2009-03-04 21:36:05ronaldoussorensetstatus: open -> closed
resolution: accepted -> fixed
messages: + msg83140
2009-02-12 15:05:17ronaldoussorensetresolution: accepted
messages: + msg81769
nosy: + ronaldoussoren
2009-02-10 02:55:50ned.deilysetfiles: + patch-nad0014-py3k-30.txt
2009-02-10 02:55:06ned.deilycreate