Hi Alex
On 17/02/2007, at 2:23 PM, Alexander Ross wrote:
Harold,
Did you also check /Library/Application Support/TextMate? Also, do you have anything special with your installation of python? Perhaps a site_customize.py in your home directory?
Sorry I forgot to mention I don't have /Library/Application Support/ TextMate directory.
Aside from the the default Apple install of python in /usr/bin/python, I have installed the recommended version of python 2.5 (Framework build) and it is linked to /usr/local/bin: /usr/local/bin/python -> ../../../Library/Frameworks/Python.framework/ Versions/2.5/bin/python (My default $PATH searches /usr/local/bin ahead of /usr/bin/ )
Can you use raw_input? Eg. try:
#!/usr/bin/python x = raw_input("Raw Input:") y = eval(x) print y
Using TextMate Version 1.5.4 (1360):
1. Only response I get is:
PyMate r6190 running Python 2.3.5 (/usr/bin/python)
test_raw_input.py
and I have to stop the task before I can close the window.
2. Running using the Run Script (Terminal) command works fine (calls pythonw rather than python):
clear; cd '/Users/harry/Desktop'; 'pythonw' '/Users/harry/Desktop/ test_raw_input.py'; rm -f ''
3. Running the old version (via pymate.py) works fine (though it appears to disregard the /usr/bin/python (2.3) for the /usr/local/bin/ python (2.5) ): HIDE STDERR SHOW STDERR Python 2.5.0 - PyMate r5848 For comments contact the author. The regular Python interpreter can be invoked using ⌘⇧R.
test_raw_input.py
123 forcing redraw!!! don't remove Script terminated with success.
I noticed that in the pymate.py code there is an explicit function for putting up a CocoaDialog input box (via raw_input_replacement (prompt='')); is the same Cocoa dialog input box supposed to come up with the Ruby code pymate.rb? This failure may be the kernel of the problem ... is there a simple test whether my ruby install is working? /usr/bin/ruby -v ruby 1.8.2 (2004-12-25) [universal-darwin8.0] file /usr/bin/ruby /usr/bin/ruby: Mach-O universal binary with 2 architectures /usr/bin/ruby (for architecture i386): Mach-O executable i386 /usr/bin/ruby (for architecture ppc): Mach-O executable ppc
Sorry to present such an intractable enigmatic problem ...
Harry.