[Zope-dev] Confused about catalog unique ID in ZScheduler
   
    Loren Stafford
     
    lstaffor@dynalogic.com
       
    Sun, 5 Mar 2000 09:54:07 -0800
    
    
  
Two questions really:
1. How do I get the uid from the catalog in a python product. Currently I
have
    for event in self._catalog.searchResults(
            nextEventTime=DateTime(1),
            nextEventTime_usage='range:min',
            sort_on='nextEventTime'
            ):
      next_url = event.absolute_url
      next_time = event.nextEventTime
      #next_uid = event.uid
      break  # just look at the first one
    return (next_uid, next_time, next_url)
...but that event.uid line isn't correct.
2. I need to add to ZScheduler the ability to delete a catalog entry if the
Dispatcher gets an error when it tries to disarm an event. Is uid what I
need in ZScheduler to subsequently do this?
      self.uncatalog_object(uid)
My confusion here is knowing that uid is based on relative URL but knowing
(vaguely) that relative URL is problematic in vurtual hosting environment
(the very reason that ZScheduler catalogs absolute_url and uses it to
identify the target ZEvent). Can someone clarify?
-- Loren