#80 Move rotting tasks up in watchdog messages
Merged 3 years ago by frantisekz. Opened 3 years ago by frantisekz.

@@ -117,6 +117,16 @@ 

          message += sync_failure.message.replace("\n", "<br />")

          message += "<hr>"

  

+     message += "<h3>Rotting Started Tasks</h3>"

+     for started_task in started_rotting_tasks:

+         message += "<b>What: </b>" + started_task.what + "<br />"

+         message += "<b>Start Time: </b>" + str(started_task.started_at) + "<br />"

+ 

+     message += "<h3>Rotting Planned Tasks</h3>"

+     for planned_task in planned_rotting_tasks:

+         message += "<b>What: </b>" + planned_task.what + "<br />"

+         message += "<b>Plan Time: </b>" + str(planned_task.planned_at) + "<br />"

+ 

      message += "<h3>Old data in DB</h3>"

      if app.config["ACTIVE_WATCHDOG"]:

          message += "<i>Counters for these tasks were reset as your oraculum instance is configured with ACTIVE_WATCHDOG</i><br />"
@@ -138,16 +148,6 @@ 

          if app.config["ACTIVE_WATCHDOG"]:

              counter = redis_conn.getset(old_data.provider, 0)

  

-     message += "<h3>Rotting Started Tasks</h3>"

-     for started_task in started_rotting_tasks:

-         message += "<b>What: </b>" + started_task.what + "<br />"

-         message += "<b>Start Time: </b>" + str(started_task.started_at) + "<br />"

- 

-     message += "<h3>Rotting Planned Tasks</h3>"

-     for planned_task in planned_rotting_tasks:

-         message += "<b>What: </b>" + planned_task.what + "<br />"

-         message += "<b>Plan Time: </b>" + str(planned_task.planned_at) + "<br />"

- 

      try:

          if not app.config["SEND_ERROR_EMAILS"]:

              raise

These errors are more important, so it makes sense to have them up in status emails

Pull-Request has been merged by frantisekz

3 years ago
Metadata