[PEAK] trivial_web on os x

Wayne Larsen wayne at larsen.st
Wed May 12 05:20:17 EDT 2004

Arg, thanks Ulrich.  I did try that, but I must have done the import  
without Zope3 in the path.  Without Zope3 in the python path, doing  
"from peak.web import interfaces" works fine, but with Zope3 in the  
path, I get the following traceback:

 >>> from peak.web import interfaces
Traceback (most recent call last):
   File "<stdin>", line 1, in ?
python2.3/site-packages/peak/web/interfaces.py", line 27, in ?
     from zope.publisher.interfaces import IPublication
__init__.py", line 23, in ?
     from zope.component.interfaces import IPresentationRequest
line 38, in ?
     getServiceManager = hookable(getServiceManager)
SystemError: NULL result without error in PyObject_Call

This is with the latest Zope3 from subversion. I downloaded X3 MS4 to  
compare, but the same thing happens.

I hacked around it - the code in zope/component/__init__.py is:
     from zope.hookable import hookable
except ImportError:
     def hookable(ob):
          return ob

I just commented out the import, and it worked fine again (though with  
MS4, there's some other problem with the up to date Zope3 source).


On 12-May-04, at 2:35 AM, Ulrich Eck wrote:

> Hi Wayne,
> try to import peak.web.interfaces from cmd-promt,
> you might see another error that's causing the
> not working import.
> cheers Ulrich
> On Wed, 2004-05-12 at 10:01, Wayne Larsen wrote:
>> I just got a mac, and I'm trying to set up PEAK in this environment.
>> It's 10.3 with the default Python install (2.3).  Running trivial_cgi
>> works fine, as does the bulletins example.  However, trivial_web is
>> causing me problems, with the following stacktrace.  This doesn't make
>> much sense to me, since IWebInteraction is definately defined in
>> peak.web.interfaces, but then I don't claim to understand the import
>> voodoo happening here.
>> Any ideas?
>> Thanks,
>> Wayne
>> Traceback (most recent call last):
>> ...
>>    File
>> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/
>> python2.3/site-packages/peak/running/commands.py", line 932, in
>> interpret
>>      cgi = adapt(ob, IRerunnableCGI, None)
>>    File "C:\cygwin\home\pje\PyProtocols\src/protocols/_speedups.pyx",
>> line 170, in _speedups.adapt
>>    File "C:\cygwin\home\pje\PyProtocols\src/protocols/_speedups.pyx",
>> line 378, in _speedups.Protocol__adapt__
>>    File
>> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/
>> python2.3/site-packages/peak/running/interfaces.py", line 153, in
>> CGIFromComponent
>>      from peak.web.publish import CGIPublisher
>>    File
>> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/
>> python2.3/site-packages/peak/web/publish.py", line 4, in ?
>>      from interfaces import *
>> AttributeError: 'LazyModule' object has no attribute 'IWebInteraction'
>> _______________________________________________
>> PEAK mailing list
>> PEAK at eby-sarna.com
>> http://www.eby-sarna.com/mailman/listinfo/peak
> _______________________________________________
> PEAK mailing list
> PEAK at eby-sarna.com
> http://www.eby-sarna.com/mailman/listinfo/peak
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/enriched
Size: 3540 bytes
Desc: not available
Url : http://www.eby-sarna.com/pipermail/peak/attachments/20040512/56e896b4/attachment.bin

More information about the PEAK mailing list