~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to scripts/script-monitor-nagios.py

  • Committer: Jeroen Vermeulen
  • Date: 2011-09-26 06:30:07 UTC
  • mto: This revision was merged to the branch mainline in revision 14049.
  • Revision ID: jeroen.vermeulen@canonical.com-20110926063007-1fb5eelnidpnra9a
Fix lots of lint in recently-changed files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
        start_date = datetime.now() - timedelta(minutes=minutes_ago)
59
59
 
60
60
        completed_from = strftime("%Y-%m-%d %H:%M:%S", start_date.timetuple())
61
 
        completed_to = strftime("%Y-%m-%d %H:%M:%S", datetime.now().timetuple())
 
61
        completed_to = strftime(
 
62
            "%Y-%m-%d %H:%M:%S", datetime.now().timetuple())
62
63
 
63
64
        hosts_scripts = []
64
65
        for arg in args:
95
96
            print "All scripts ran as expected"
96
97
            return 0
97
98
    except Exception, e:
98
 
        # Squeeze the exception type and stringification of the exception value
99
 
        # on to one line.
 
99
        # Squeeze the exception type and stringification of the exception
 
100
        # value on to one line.
100
101
        print "Unhandled exception: %s %r" % (e.__class__.__name__, str(e))
101
102
        return 3
102
103