[Zope] __basicnew__ errors

seb bacon seb@jamkit.com
Fri, 20 Apr 2001 11:31:49 +0100


* Brian Lloyd <brian@digicool.com> [010420 00:15]:
> > Whenever I try to import an object from one Zope (2.3.0) to another
> > (2.3.1) I get a 
> > 
> >   Error Type: AttributeError
> >   Error Value: __basicnew__
> > 
> > <snip> 
> >
> > Why might this be?  Can anyone shed any light onto what __basicnew__
> > does?  
> 
> __basicnew__ is a rather low-level initialization method in 
> ExtensionClass... I've never seen this before though :(
> 
> > And has anyone any pointers to understanding these pickled
> > traceback things?  Whenever they occur, I find it's usually due to
> > inconsistencies between the pickled product-related info and the
> > products loaded from the filesystem, but I don't know how to go about
> > debugging it.
> 
> There is definitely some problem unpickling one or more of the 
> objects stored in the db (the junk in the traceback is the 
> actual pickle string), but I don't have a quick answer for 
> you on the cause here. Is it possible that you forgot to 
> copy over a (filesystem) product that defines a base class 
> or something used by these instances?

Yes, it was something like that.  The problem went away when I
resynched the Products directories between the two installs, so there
must have been inconsistencies between Product version.  Personally I
suspect different versions of ZPatterns.  

This broken product problem occurs frequently on the lists.  I've
never looked  at the unpickling / db loading code, but I
wonder if there's a way of better identifying broken products at
startup time?  Or is there a bootstrapping issue which makes this
impossible?

cheers,

seb