[Zope] test code for reindexing problem

Deb Richardson deb@hub.org
Sat, 03 Jun 2000 12:09:13 -0400


I'm still working on figuring out what I'm doing wrong with my ZCatalog
stuff.  I must be doing something wrong because my catalog not only
doesn't seem to reindex properly, it also tends to get corrupted every
once in a while...I think I'm doing Bad Things to my ZCatalog, I just
don't know what they are.  

I've created a BugTrack Product and test stuff that replicates the
problem.

You can see it in action here:

http://www.oswg.org:8080/bug_tracker/

To change the item_name property of one of the items, go to "View
Catalog Listing / Item Listing" and click the linked ID number.  After
the item is edited, go back to the "View Catalog..." page, and you'll
see that the bobobase_modification_time has been updated in the "ACTUAL
ITEMS" table, but not in the "CATALOG ITEMS" table.  

(The catalog might also just randomly break, which it tends to do...not
returning all items, etc.  I have no idea what's causing that, either,
but I'm hoping they're related problems).

My actual code, including the BugTracker Product & example folder .zexp
files, is available here:

hgttp://www.dria.org/bugtrack.tar.gz

NOTE: in the example "bugtrack_addForm" a method "RANDOM_GEN" is used. 
That's just a simple dtml method that sits at the top of my zope tree
and contains:

   <dtml-let RNDM="_.random.random()">
   <dtml-let RNDM="_.int(RNDM*1000000)">
   <dtml-var RNDM fmt="%06d"></dtml-let></dtml-let>

I use it for generating random IDs.

I also hardcoded "http://www.oswg.org:8080/" in the "bugtracker_report"
method, just so you know.


- deb