Revision: 389
Author: bslatkin
Date: Wed Sep 22 15:54:24 2010
Log: fix manual run of cleanup subs MR
http://code.google.com/p/pubsubhubbub/source/detail?r=389

Modified:
 /trunk/hub/offline_jobs.py

=======================================
--- /trunk/hub/offline_jobs.py  Wed Sep 22 15:16:49 2010
+++ /trunk/hub/offline_jobs.py  Wed Sep 22 15:54:24 2010
@@ -78,8 +78,10 @@

     if self.threshold_timestamp is None:
       params = context.get().mapreduce_spec.params
+      if 'threshold_timestamp' not in params:
+        params = context.get().mapreduce_spec.mapper.params
       self.threshold_timestamp = datetime.datetime.utcfromtimestamp(
-          params['threshold_timestamp'])
+          float(params['threshold_timestamp']))

     if sub.expiration_time < self.threshold_timestamp:
       sub.request_insert(sub.callback, sub.topic, sub.verify_token,

Reply via email to