2.5b4 Win2k problem - 'module' object has no attribute 'compile'
Just did a fresh install of Zope 2.50b4 on a Win2k machine, and when running z2.py get this: ------ Traceback (most recent call last): File "C:\Zope\Zope250\z2.py", line 540, in ? import ZServer File "C:\Zope\Zope250\ZServer\__init__.py", line 80, in ? from HTTPServer import zhttp_server, zhttp_handler File "C:\Zope\Zope250\ZServer\HTTPServer.py", line 43, in ? from PubCore import handle File "C:\Zope\Zope250\ZServer\PubCore\__init__.py", line 14, in ? import ZRendezvous File "C:\Zope\Zope250\ZServer\PubCore\ZRendezvous.py", line 15, in ? from ZServerPublisher import ZServerPublisher File "C:\Zope\Zope250\ZServer\PubCore\ZServerPublisher.py", line 13, in ? from ZPublisher import publish_module File "C:\Zope\Zope250\lib\python\ZPublisher\__init__.py", line 23, in ? from Publish import publish_module, Retry File "C:\Zope\Zope250\lib\python\ZPublisher\Publish.py", line 19, in ? from Response import Response File "C:\Zope\Zope250\lib\python\ZPublisher\Response.py", line 13, in ? import HTTPResponse File "C:\Zope\Zope250\lib\python\ZPublisher\HTTPResponse.py", line 91, in ? start_of_header_search=re.compile('(<head[^>]*>)', re.IGNORECASE).search AttributeError: 'module' object has no attribute 'compile' ------ (Had this happen on another Win2k machine too. However 2.50 Beta 3 worked fine on that same machine) Anybody have a fix? Barry
Hello All! Let me tell you what I am trying to set up and about the way I am thinking of doing this. Maybe someone has a product or a script that does something similar or can tell me how to accomplish my idea. I am trying to run a page on my shopping web site that has the ability to give the customers status of their order. I do not know how to accomplish this yet all I know is that the idea I stole from dell. The way you can log in to their site and be able to see where in the process the system is. Basically a uniqe page customised by each user. I was thinking of two ways to accomplish this. 1. Find some way that a web page inside zope can be redirected to another web page based on the user ID. This would be the simplest way since I can then provide dynamic information pulling on different dtml methods and database queries (leaving the authentication to zope). 2. Create the whole thing via queries and serv it up via zope. This would be a royal pain since I would have to recreate the whole authentication part in the database and can not use zope authentication for this. So if you have any ideas I would love to hear them.
If you would like your brain to explode <joke>, have a look at the CMF coupled with DCWorkflow http://cmf.zope.org/Members/hathawsh/DCWorkflow/DCWorkflow-0.4.2.tar.gz/view What you need would be a Python Product (or ZClass) designed to work in the CMF, DCWorkflow, and the backend database. This would allow a start-to-finish means of following the order. When a user creates the order, the state is new. When someone in your company accepts the order, they change the status to 'in process' or something. After shipping, change the order status to 'shipped'. DCWorkflow rocks! Oh. That sound was my brain exploding. Troy -- Troy Farrell Developer Entheos Software mailto:troy@entheossoft.com http://www.entheossoft.com Yury German wrote:
Hello All!
Let me tell you what I am trying to set up and about the way I am thinking of doing this. Maybe someone has a product or a script that does something similar or can tell me how to accomplish my idea.
I am trying to run a page on my shopping web site that has the ability to give the customers status of their order. I do not know how to accomplish this yet all I know is that the idea I stole from dell. The way you can log in to their site and be able to see where in the process the system is.
Basically a uniqe page customised by each user.
I was thinking of two ways to accomplish this.
1. Find some way that a web page inside zope can be redirected to another web page based on the user ID. This would be the simplest way since I can then provide dynamic information pulling on different dtml methods and database queries (leaving the authentication to zope).
2. Create the whole thing via queries and serv it up via zope. This would be a royal pain since I would have to recreate the whole authentication part in the database and can not use zope authentication for this.
So if you have any ideas I would love to hear them.
Quoting Barry Pederson <barryp@medicine.nodak.edu>:
Just did a fresh install of Zope 2.50b4 on a Win2k machine, and when running z2.py get this:
File "C:\Zope\Zope250\lib\python\ZPublisher\HTTPResponse.py", line 91, in ? start_of_header_search=re.compile('(<head[^>]*>)', re.IGNORECASE).search AttributeError: 'module' object has no attribute 'compile' ------
(Had this happen on another Win2k machine too. However 2.50 Beta 3 worked fine on that same machine)
Just to follow up to my own message, that problem seems to be caused by accidentally using the wrong version of Python. I had Python 2.2 installed on both boxes, which would have been what was running when I just typed "z2.py" at the command-line. Making sure to use the included Python 2.1.1+ (easy to do by using the "start.bat") works fine. Barry
participants (3)
-
Barry Pederson -
Troy Farrell -
Yury German