More on the Rx Toolkit change in 5.2.0
Eric Promislow <[email protected]> Fri, 18 Sep 2009 09:59:34 -0700
| Newsgroups | gmane.comp.ide.komodo.general |
|---|---|
| Message-ID | <[email protected]> |
Some of you on Windows have found the Rx Toolkit wasn't working in Komodo 5.2.0. The old Rx toolkit used to run in process, which meant if you entered an expense regex, or entered a lot of text, Komodo would be unresponsive until it was finished. Additionally, it accepted only the Python regex language. We've started to change Rx to make it more modular. The first step was to move the pattern-matching to an external Python process. The next step will be to show you how a particular regex works with other languages. This is a good way of answering a question like whether the language you're using supports something like the "(?<)" assertion. Unfortunately, I did all my testing on fully-loaded dev machines, and we ended up shipping an Rx that has a dependency on ActivePython. In particular, this affects Windows and the OS X versions. There are two ways to fix this on Windows, two on OS X. 1. On either platform, install ActivePython 2.6 from http://downloads.activestate.com/ActivePython/. If you're on OS X you don't even need to put it in your path -- The Komodo Python is looking for a library, not the executable. 2. On Windows, run the following commands so the python.exe the Rx toolkit shells out to can find the correct python DLL: * Bring up a command window, or use the file manager * cd to "c:\Program Files\ActiveState Komodo IDE 5" (or where ever you installed Komodo) * cd lib * copy mozilla\python26.dll python\python26.dll * Restart the Rx Toolkit (a Komodo restart shouldn't be necessary). 3. On OS X, bring up a terminal window, cd into the Komodo app dir at .../Komodo IDE.app/Contents/MacOS/components, and make the following change in the file koDirs.py: * find the get_pythonExe function * change the code so it reads like so: ....def get_pythonExe(self): ........if sys.platform == "darwin": ............pythonExe = join(self.get_mozBinDir(), "mozpython") ........elif sys.platform == "win32" # leave the rest alone Those leading periods are meant to show you how many spaces need to be at the start of each line. Python is whitespace-sensitive; an error here can result in Komodo failing to run completely. ===== I'm sorry about the inconvenience. It turns out there are only two other areas in Komodo where we invoke Komodo's internal python.exe this way, and they have the same problems, but they're used far less often than the Rx Toolkit, evidently (they're in the Komodo Extension and Firefox Extension project templates, if you're wondering). - Eric Promislow _______________________________________________ Komodo-discuss mailing list [email protected] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs Other options: http://listserv.ActiveState.com/mailman/listinfo/Komodo-discuss