[Pythonmac-SIG] Re: Namespace conflict with WebWare and PyObjC / Import safety (Was: how do I use twisted cfreactor?)

2005-01-14 Thread Kevin Dangoor
Fun indeed. Given that I'm not using WebWare, it would most definitely be picking up PyObjC's WebKit. Maybe there's something to be said for Java's package naming conventions :) The py2app issue I was having was far less exciting. Cheetah seems to like dumping templates into /tmp and it drops i

[Pythonmac-SIG] Cheetah Templates and py2app (Was: how do I use twisted cfreactor?)

2005-01-14 Thread Bob Ippolito
Somebody else had a Cheetah and template issue with py2app. The custom import hook is not recognized by py2app and I have no interest in writing that kind of Cheetah-specific stuff at this time (I don't use it, and I actually really don't like anything about it). The person who had that probl

Re: [Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Kevin Dangoor
That's good to hear. The more I thought about it, the more it seems like there are other cases where "non-standard" imports are more than a little useful. I'm actually running into another Cheetah-related problem when I use py2app (though this one is very clearly in Cheetah land), and it's also

[Pythonmac-SIG] Namespace conflict with WebWare and PyObjC / Import safety (Was: how do I use twisted cfreactor?)

2005-01-14 Thread Bob Ippolito
On Jan 14, 2005, at 17:14, Bob Ippolito wrote: On Jan 14, 2005, at 16:56, Kevin Dangoor wrote: Bob Ippolito wrote: (Kevin sent me the test off-list, and I took a look at it). I'm not sure exactly why your example crashes (somehow a retain message gets sent to a dead or non-object), however, the pr

Re: [Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Bob Ippolito
I don't think there is typically a gotcha with imports, I've certainly never seen this happen before, and I have done imports from applicationDidFinishLaunching: (pygame, in particular) before. I have no idea if I should be blaming Cheetah, PyObjC or Python 2.3.0 (haven't tested with 2.4 or CV

Re: [Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Kevin Dangoor
Wow. That was quick! I didn't realize that there was a gotcha with the imports. That was just a premature optimization, so I can easily avoid that :) Thanks for your help... that's certainly not the kind of thing I would have just guessed... Kevin Bob Ippolito wrote: (Kevin sent me the test off

Re: [Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Bob Ippolito
(Kevin sent me the test off-list, and I took a look at it). I'm not sure exactly why your example crashes (somehow a retain message gets sent to a dead or non-object), however, the problem is that you are using an import statement from inside the implementation of the action. Don't do that. Do

Re: [Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Bob Ippolito
The issue you're having sounds like it's either something really easy or really hard to fix. If you post code I'll track it down, but I don't have the time this weekend to debug-by-mail. Your crash aside, it should be done in this order: 1) Install cfreactor 2) Load up all the classes 3) AppHel

Re: [Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Kevin Dangoor
Replying to myself is always fun. I decided to try a more minimal test, eliminating everything but PyObjC and Cheetah. It does indeed appear to be the case that I get a Bus Error if I render a Cheetah template from within an action called by a menu item. This happens even when Cheetah is 100% py

Re: [Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Kevin Dangoor
Replying to myself is always fun. I decided to try a more minimal test, eliminating everything but PyObjC and Cheetah. It does indeed appear to be the case that I get a Bus Error if I render a Cheetah template from within an action called by a menu item. This happens even when Cheetah is 100% py

[Pythonmac-SIG] how do I use twisted cfreactor?

2005-01-14 Thread Kevin Dangoor
I'm trying to mix Twisted and a Mac interface. I'm using PyObjC 1.2 and Twisted's trunk as of a few days back. All of this with Python 2.3. The combo appeared to be working until this morning. Intriguingly, the problem appeared when I added Cheetah (the template engine) to the mix. If I remo

Re: [Pythonmac-SIG] Anyone script ChemDraw w/ Python?

2005-01-14 Thread has
fbartlet wrote: I have a mess of VBA and AppleScript scripts I wrote to automate Word & ChemDraw tasks. Now that everyone who needs this stuff has access to OS X, I thought I might try Python to make some improvements I've been asked for and which VBA and AppleScript don't seem to be able to de

Re: [Pythonmac-SIG] Using .pth to adjust Python on startup

2005-01-14 Thread Bob Ippolito
On Jan 14, 2005, at 13:29, Robert White wrote: Last night, while researching a different problem, I ran across the usage of 'import' within ".pth" to run arbitrary code as the Python environment is being initialized. I believe that this provides an alternative to using PYTHONPATH and possibly s

Re: [Pythonmac-SIG] Folder Actions in Python?

2005-01-14 Thread has
Wolfgang Keller wrote: Is there a way to write "folder actions" for MacOS X in Python? Ideally, you'd use PythonOSA , but it doesn't yet support handling of arbitrary Apple events. For now, your options are: 1. Use an AppleScript to run your Pyt

[Pythonmac-SIG] Using .pth to adjust Python on startup

2005-01-14 Thread Robert White
Last night, while researching a different problem, I ran across the usage of 'import' within ".pth" to run arbitrary code as the Python environment is being initialized. I believe that this provides an alternative to using PYTHONPATH and possibly some of the other environment variables via "~/.Ma

Re: [Pythonmac-SIG] Any suggestions for a questionnaire site?

2005-01-14 Thread Bob Ippolito
On Jan 14, 2005, at 9:58, Dethe Elza wrote: No personal experience with these, but a quick google shows: http://free-online-surveys.co.uk/ http://freesurveysonline.com/ http://freeonlinesurveys.com/ No idea how reputable any of these are... If all you want is a simple poll, my livingcode.org site i

[Pythonmac-SIG] Anyone script ChemDraw w/ Python?

2005-01-14 Thread fbartlet
Gentlefolk, I have a mess of VBA and AppleScript scripts I wrote to automate Word & ChemDraw tasks. Now that everyone who needs this stuff has access to OS X, I thought I might try Python to make some improvements I've been asked for and which VBA and AppleScript don't seem to be able to delive

Re: [Pythonmac-SIG] Any suggestions for a questionnaire site?

2005-01-14 Thread Dethe Elza
Jack, No personal experience with these, but a quick google shows: http://free-online-surveys.co.uk/ http://freesurveysonline.com/ http://freeonlinesurveys.com/ No idea how reputable any of these are... If all you want is a simple poll, my livingcode.org site is running on DreamHost, which offers

Re: [Pythonmac-SIG] Python access to RS-232, USB, MIDI?

2005-01-14 Thread Arthur Elsenaar
On Jan 14, 2005, at 02:10, Lance Boyle wrote: I'm brainstorming on a project that involves communicating with a head tracker (I need only azimuth). I haven't decided on an actual head tracker, but am looking at a Polhemus. (Comments on head trackers are also welcomed--gaming devices or 3D mice?)

Re: [Pythonmac-SIG] Folder Actions in Python?

2005-01-14 Thread Michael J. Barber
You could write a folder action in AppleScript that uses "do shell script" in the Standard Additions to call out to a python script. The amount of AppleScript needed should be pretty minimal. On Jan 13, 2005, at 8:03 PM, Wolfgang Keller wrote: Is there a way to write "folder actions" for MacOS X

[Pythonmac-SIG] Any suggestions for a questionnaire site?

2005-01-14 Thread Jack Jansen
Folks, I want to do a questionnaire shortly, on the subject of which installers people want most (2.{3,4}.X for 10.{2,3}, mainly). That'll help me spend my time most efficiently (my MacPython time, that is:-) Does anyone know of a decent site that hosts such questionnaires that is both easy to