Re: [Zope-dev] ghosts of removed products haunting ZSQL Methods?

2002-01-08 Thread Matthew T. Kromer

John Ziniti wrote:

 I used to have the Product TrackerBase installed
 and have removed it.  Now, however, attempts to
 access the Advanced tab of ZSQL Methods is
 broken because a chain of events attempt to get
 info about a the non-existent Product:

 lib/python/Shared/DC/ZRDB/dtml/advanced.dtml calls
 manage_product_zclass_info

 ../ZRDB/DA.py.manage_product_zclass_info (line 546)
 calls self.aq_acquire('_getProductRegistryData')('zclasses')

 One of these items is the dict:
   {'id': 'Tracker', 'meta_type': 'Tracker',
 'product': 'Tracker', 'meta_class': ZClass instance at d55af0}

 Then, line 548 calls if hasattr(z._zclass_,'_p_deactivate').

 The attempt to access z._zclass_ fails because this
 product doesn't exist.

 1) the call to z._zclass_ doesn't actuallt do anything
except: ## Eek, persistent

 2) Is this schizophrenic state my fault?

 3) How to rectify the problem (Make *all* of Zope
know that TrackerBase is gone)?


Hi John,

I'm ready and eager to blame Z classes for everything :)

In this case, lets try to force ZClasses to fix themselves up by going 
into Zope at the python command line prompt

% cd lib/python
% python2.1.1
  import Zope
  app = Zope.app()
  app.fixupZClassDependencies(rebuild=1)
  get_transaction().commit()

Hopefully that will do it for you.




___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] ghosts of removed products haunting ZSQL Methods?

2002-01-08 Thread John Ziniti

 I'm ready and eager to blame Z classes for everything :)


Yeah, me too, hatin' em right about now ...

 % cd lib/python
 % python2.1.1
   import Zope
   app = Zope.app()
   app.fixupZClassDependencies(rebuild=1)
   get_transaction().commit()
 
 Hopefully that will do it for you.


Found that on a mailinglist archive last night.  Tried
it but it doesn't work.  The offending Product's
ZClasses are still in the Registry (but nowhere else).



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] ghosts of removed products haunting ZSQL Methods?

2002-01-08 Thread Dieter Maurer

John Ziniti writes:
  I used to have the Product TrackerBase installed
  and have removed it.  Now, however, attempts to
  access the Advanced tab of ZSQL Methods is
  broken because a chain of events attempt to get
  info about a the non-existent Product:
  ...
  2) Is this schizophrenic state my fault?
Probably not.

Looks like a bug, you should report to http://collector.zope.org;.

  3) How to rectify the problem (Make *all* of Zope
  know that TrackerBase is gone)?
I think this is the right approach.


Dieter

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] ghosts of removed products haunting ZSQL Methods?

2002-01-08 Thread John Ziniti

Dieter Maurer wrote:

John Ziniti writes:
  I used to have the Product TrackerBase installed
  and have removed it.  Now, however, attempts to
  access the Advanced tab of ZSQL Methods is
  broken because a chain of events attempt to get
  info about a the non-existent Product:
  ...
  2) Is this schizophrenic state my fault?
Probably not.

I didn't think so, but I would think that the code which deletes
Products and their associated ZClasses would be pretty rock
solid at this point ??

Looks like a bug, you should report to http://collector.zope.org;.

I would, but as a developer myself, a bug that has a symptom
bu no real evidence of a cause is one I wouldn't really think to
look at it.  My ZODB is broken is basically the best I can
come up with at this point as a way to explain my problem.  I
can talk all the way in to Zope.app()._getProductRegistryData()
about the way the problem manifests itself, but it happened at
some point over the last ... oh ... three months of development???
It'll get ignored, for sure ... ( no offense intended)

 3) How to rectify the problem (Make *all* of Zope
  know that TrackerBase is gone)?
I think this is the right approach.

Yep.  I really just want to try something akin to:

old_registry=app._getProductRegistryData('zclasses')
app._SetProductRegistryData('zclasses')=old_registry[1:]

... but I'd like to hear from the guy who wrote _getProductRegistryData
first before I even try it on a backup-devlopment-Zope.


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )