Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #8316 > unrolled thread

Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work

Started bymando <mandoluca@gmail.com>
First post2011-06-23 10:38 -0700
Last post2011-06-28 06:27 -0700
Articles 7 — 2 participants

Back to article view | Back to comp.lang.python


Contents

  Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work mando <mandoluca@gmail.com> - 2011-06-23 10:38 -0700
    Re: Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work Ned Deily <nad@acm.org> - 2011-06-23 13:52 -0700
      Re: Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work mando <mandoluca@gmail.com> - 2011-06-24 00:33 -0700
        Re: Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work Ned Deily <nad@acm.org> - 2011-06-24 14:01 -0700
          Re: Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work mando <mandoluca@gmail.com> - 2011-06-28 00:53 -0700
            Re: Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work Ned Deily <nad@acm.org> - 2011-06-28 01:49 -0700
          Re: Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work mando <mandoluca@gmail.com> - 2011-06-28 06:27 -0700

#8316 — Mac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work

Frommando <mandoluca@gmail.com>
Date2011-06-23 10:38 -0700
SubjectMac OS X 10.6.6 and MacPyhton 2.6 idle doesn't work
Message-ID<198e388e-57ce-42e4-acff-48bed83563ee@m22g2000yqh.googlegroups.com>
I've installed MacPython 2.6 under mac os x 2.6 and the IDLE doesn't
work.
I post error log. Suggestions?

Thanks a lot.

Luca


23/06/11 19.18.01       Apple80211 framework[211]
ACInterfaceGetPower called
with NULL interface
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]
Traceback (most
recent call last):
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]      File
"/
Applications/Python 2.6/IDLE.app/Contents/Resources/idlemain.py",
line
30, in <module>
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]
main()
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]      File
"/
Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
idlelib/
PyShell.py", line 1382, in main
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]
root =
Tk(className="Idle")
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]      File
"/
Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-
tk/
Tkinter.py", line 1645, in __init__
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]
self._loadtk()
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]      File
"/
Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-
tk/
Tkinter.py", line 1659, in _loadtk
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]        %
(_tkinter.TK_VERSION, tk_version)
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]
RuntimeError:
23/06/11 19.18.01       [0x0-0x1f61f6].org.python.IDLE[2470]    tk.h
version
(8.4) doesn't match libtk.a version (8.5)
23/06/11 19.18.01       com.apple.launchd.peruser.502[203]
([0x0-0x1f61f6].org.python.IDLE[2470]) Exited with exit code: 1

[toc] | [next] | [standalone]


#8327

FromNed Deily <nad@acm.org>
Date2011-06-23 13:52 -0700
Message-ID<mailman.341.1308862358.1164.python-list@python.org>
In reply to#8316
In article <1308852410.2257.1466520017@webmail.messagingengine.com>,
 python@bdurham.com wrote:
> > You'll have to install Tcl yourself. The 2.6 binaries were
> compiled against a newer version than Apple ships.
> 
> Does this requirement apply to Python 2.7 or Python 3.2 for the
> Mac or is this requirement Python 2.6 specific?

I don't quite understand what's going on there.  To the OP: when you say 
MacPython 2.6, from where did you install it or did you build it 
yourself?  In OS X 10.6, Apple ships framework versions of both Tcl/Tk 
8.4 and 8.5.  Be aware that the 8.5 version shipped by Apple is known to 
be very problematic with IDLE and Tkinter.  If building youself, install 
the ActiveState Tcl/Tk 8.5 or stick to 8.4.  The most recent python.org 
OS X installer for 2.6 was 2.6.5 
(http://www.python.org/download/releases/2.6.5/) and should work just 
fine with the Apple-supplied Tcl/Tk 8.4 or with ActiveState Tcl/Tk 8.4.   
More info here:

http://www.python.org/download/mac/tcltk/

-- 
 Ned Deily,
 nad@acm.org

[toc] | [prev] | [next] | [standalone]


#8355

Frommando <mandoluca@gmail.com>
Date2011-06-24 00:33 -0700
Message-ID<09cae8bf-4b1f-40ea-af36-4ba130c41949@m18g2000vbl.googlegroups.com>
In reply to#8327
I took MacPython 2.6 from here:

http://www.python.org/ftp/python/2.6.6/python-2.6.6-macosx10.3.dmg


Also I downloaded Tcl/Tk from here http://www.kyngchaos.com/software/frameworks
to using the gis software Qgis....

May be here the issue?

[toc] | [prev] | [next] | [standalone]


#8409

FromNed Deily <nad@acm.org>
Date2011-06-24 14:01 -0700
Message-ID<mailman.387.1308949334.1164.python-list@python.org>
In reply to#8355
In article 
<09cae8bf-4b1f-40ea-af36-4ba130c41949@m18g2000vbl.googlegroups.com>,
 mando <mandoluca@gmail.com> wrote:

> I took MacPython 2.6 from here:
> 
> http://www.python.org/ftp/python/2.6.6/python-2.6.6-macosx10.3.dmg
> 
> 
> Also I downloaded Tcl/Tk from here 
> http://www.kyngchaos.com/software/frameworks
> to using the gis software Qgis....
> 
> May be here the issue?

I can't reproduce the problem and I really don't see how installing that 
Tcl/Tk framework could cause the problem by itself.  The version of Tcl 
and Tk to dynamically load is added to the executable at link time when 
the installer is being built.  It should look something like this:

$ cd /Library/Frameworks/Python.framework/Versions/2.6
$ cd ./lib/python2.6/lib-dynload/
$ otool -L _tkinter.so 
_tkinter.so (architecture ppc):
   /Library/Frameworks/Tcl.framework/Versions/8.4/Tcl (compatibility 
version 8.4.0, current version 8.4.19)
   /Library/Frameworks/Tk.framework/Versions/8.4/Tk (compatibility 
version 8.4.0, current version 8.4.19)
   /usr/lib/libmx.A.dylib (compatibility version 1.0.0, current version 
47.1.0)
   /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current 
version 88.3.10)
_tkinter.so (architecture i386):
   /Library/Frameworks/Tcl.framework/Versions/8.4/Tcl (compatibility 
version 8.4.0, current version 8.4.19)
   /Library/Frameworks/Tk.framework/Versions/8.4/Tk (compatibility 
version 8.4.0, current version 8.4.19)
   /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current 
version 88.3.10)

Note the absolute path to the framework.  If that version of the 
framework does not exist at that location, the dynamic loader falls back 
to the OS X standard location /System/Library/Frameworks ...

If you've only installed that one extra Tcl/Tk version, things should 
look something like this:

$ ls -l /Library/Frameworks/Tcl.framework/Versions/
total 8
drwxr-xr-x  5 root  admin  272 Jul 27  2010 8.5/
lrwxr-xr-x  1 root  admin    3 Jun 24 13:31 Current@ -> 8.5
$ ls -l /Library/Frameworks/Tk.framework/Versions/
total 8
drwxr-xr-x  5 root         admin  272 Jul 27  2010 8.5/
lrwxr-xr-x  1 sysadminold  wheel    3 Jun 24 13:31 Current@ -> 8.5
$  ls -l /System/Library/Frameworks/Tk.framework/Versions/
total 8
drwxr-xr-x  5 root  wheel  340 Mar 17 18:27 8.4/
drwxr-xr-x  5 root  wheel  340 Mar 17 18:27 8.5/
lrwxr-xr-x  1 root  wheel    3 Nov  7  2010 Current@ -> 8.5
$ ls -l /System/Library/Frameworks/Tcl.framework/Versions/
total 8
drwxr-xr-x  5 root  wheel  374 Mar 17 18:27 8.4/
drwxr-xr-x  5 root  wheel  374 Mar 17 18:27 8.5/
lrwxr-xr-x  1 root  wheel    3 Nov  7  2010 Current@ -> 8.5

If not, something's wrong.  It's especially odd that you would see a 
problem with IDLE.app since it is not influenced by shell initialization 
steps.  Do you have something set in ~/.MacOSX/environment.plist ?  
Also, try launching that idle from a shell:

$ /usr/local/bin/idle2.6

-- 
 Ned Deily,
 nad@acm.org

[toc] | [prev] | [next] | [standalone]


#8527

Frommando <mandoluca@gmail.com>
Date2011-06-28 00:53 -0700
Message-ID<7e5a3cc6-93d0-4750-93cd-fe721960d706@u26g2000vby.googlegroups.com>
In reply to#8409
This is the result of the test you suggested to me. What do you think?

Last login: Mon Jun 27 19:35:21 on ttys000
host220-186-dynamic:~ luca$ cd /Library/Frameworks/Python.framework/
Versions/2.6
host220-186-dynamic:2.6 luca$ cd ./lib/python2.6/lib-dynload/
host220-186-dynamic:lib-dynload luca$ otool -L _tkinter.so
_tkinter.so (architecture ppc):
	/Library/Frameworks/Tcl.framework/Versions/8.5/Tcl (compatibility
version 8.5.0, current version 8.5.1)
	/Library/Frameworks/Tk.framework/Versions/8.5/Tk (compatibility
version 8.5.0, current version 8.5.1)
	/usr/lib/libmx.A.dylib (compatibility version 1.0.0, current version
47.1.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 88.3.9)
_tkinter.so (architecture i386):
	/Library/Frameworks/Tcl.framework/Versions/8.5/Tcl (compatibility
version 8.5.0, current version 8.5.1)
	/Library/Frameworks/Tk.framework/Versions/8.5/Tk (compatibility
version 8.5.0, current version 8.5.1)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 88.3.9)
host220-186-dynamic:lib-dynload luca$ ls -l /Library/Frameworks/
Tcl.framework/Versions/
total 8
drwxr-xr-x  8 root  admin  272 23 Giu 15:57 8.5
lrwxr-xr-x  1 root  admin    3 23 Giu 15:57 Current -> 8.5
host220-186-dynamic:lib-dynload luca$ ls -l /Library/Frameworks/
Tk.framework/Versions/
total 8
drwxr-xr-x  8 root  admin  272 23 Giu 15:57 8.5
lrwxr-xr-x  1 503   wheel    3 23 Giu 15:57 Current -> 8.5
host220-186-dynamic:lib-dynload luca$ ls -l /System/Library/Frameworks/
Tk.framework/Versions/
total 8
drwxr-xr-x  10 root  wheel  340 23 Giu 21:53 8.4
drwxr-xr-x  10 root  wheel  340 23 Giu 21:53 8.5
lrwxr-xr-x   1 root  wheel    3 12 Ott  2010 Current -> 8.5
host220-186-dynamic:lib-dynload luca$ ls -l /System/Library/Frameworks/
Tcl.framework/Versions/
total 8
drwxr-xr-x  11 root  wheel  374 23 Giu 21:53 8.4
drwxr-xr-x  11 root  wheel  374 23 Giu 21:53 8.5
lrwxr-xr-x   1 root  wheel    3 12 Ott  2010 Current -> 8.5
host220-186-dynamic:lib-dynload luca$ sudo /usr/local/bin/idle2.6
Password:
Traceback (most recent call last):
  File "/usr/local/bin/idle2.6", line 5, in <module>
    main()
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/
python2.6/idlelib/PyShell.py", line 1382, in main
    root = Tk(className="Idle")
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/
python2.6/lib-tk/Tkinter.py", line 1645, in __init__
    self._loadtk()
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/
python2.6/lib-tk/Tkinter.py", line 1659, in _loadtk
    % (_tkinter.TK_VERSION, tk_version)
RuntimeError: tk.h version (8.4) doesn't match libtk.a version (8.5)

[toc] | [prev] | [next] | [standalone]


#8531

FromNed Deily <nad@acm.org>
Date2011-06-28 01:49 -0700
Message-ID<mailman.475.1309250985.1164.python-list@python.org>
In reply to#8527
In article 
<7e5a3cc6-93d0-4750-93cd-fe721960d706@u26g2000vby.googlegroups.com>,
 mando <mandoluca@gmail.com> wrote:
> This is the result of the test you suggested to me. What do you think?
> 
> Last login: Mon Jun 27 19:35:21 on ttys000
> host220-186-dynamic:~ luca$ cd /Library/Frameworks/Python.framework/
> Versions/2.6
> host220-186-dynamic:2.6 luca$ cd ./lib/python2.6/lib-dynload/
> host220-186-dynamic:lib-dynload luca$ otool -L _tkinter.so
> _tkinter.so (architecture ppc):
> 	/Library/Frameworks/Tcl.framework/Versions/8.5/Tcl (compatibility
> version 8.5.0, current version 8.5.1)
> 	/Library/Frameworks/Tk.framework/Versions/8.5/Tk (compatibility
> version 8.5.0, current version 8.5.1)
> 	/usr/lib/libmx.A.dylib (compatibility version 1.0.0, current version
> 47.1.0)
> 	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
> version 88.3.9)
> _tkinter.so (architecture i386):
> 	/Library/Frameworks/Tcl.framework/Versions/8.5/Tcl (compatibility
> version 8.5.0, current version 8.5.1)
> 	/Library/Frameworks/Tk.framework/Versions/8.5/Tk (compatibility
> version 8.5.0, current version 8.5.1)
> 	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
> version 88.3.9)

I'm not sure where you got that version of Python from but the output 
from otool is definitely not that of a _tkinter.so from the standard 
python.org 2.6.6 installer and it explains the results you are seeing. 
 If you want to stick with the python.org Python 2.6, I suggest you 
download the latest installer from here:
   http://python.org/download/releases/2.6.6/
and re-install.

Good luck.

-- 
 Ned Deily,
 nad@acm.org

[toc] | [prev] | [next] | [standalone]


#8536

Frommando <mandoluca@gmail.com>
Date2011-06-28 06:27 -0700
Message-ID<2db94f8b-2dea-4c07-a309-4500622f3c97@b2g2000vbo.googlegroups.com>
In reply to#8409
Why my post aren't here?

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web