Commits

Benoit Boissinot  committed 598d1c7

change timeouts for re-fetch

  • Participants
  • Parent commits 08f77b4

Comments (0)

Files changed (1)

                 try:
                     newarticle(today - timedelta(i))
                 except Exception, err:
-                    logging.info("Failed to fetch %s" % err)
+                    logging.info("Init: failed to fetch %s" % err)
 
-        if self.last_update.timestamp + timedelta(hours=6) < now and last[0].timestamp.date() != today:
+        if self.last_update.timestamp + timedelta(hours=3) < now and last[0].timestamp.date() != today:
             try:
                 newarticle(today)
             except Exception, err:
                 logging.info("Failed to fetch %s" % err)
-            else:
-                self.last_update.timestamp = now
-                self.last_update.put()
+            self.last_update.timestamp = now
+            self.last_update.put()
 
         q = FeedArticle.all().order('-timestamp')
         self.articles = q.fetch(10)