From b8a78408ff194ca2f822979fec5598778eff5826 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Tue, 21 Sep 2010 17:29:45 -0500 Subject: Small updates to mirrorcheck command Signed-off-by: Dan McGee --- mirrors/management/commands/mirrorcheck.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'mirrors/management/commands') diff --git a/mirrors/management/commands/mirrorcheck.py b/mirrors/management/commands/mirrorcheck.py index c2ab077..1662b15 100644 --- a/mirrors/management/commands/mirrorcheck.py +++ b/mirrors/management/commands/mirrorcheck.py @@ -42,7 +42,7 @@ class Command(NoArgsCommand): if v == 0: logger.level = ERROR elif v == 1: - logger.level = INFO + logger.level = WARNING elif v == 2: logger.level = DEBUG @@ -84,8 +84,10 @@ def check_mirror_url(mirror_url): try: parsed_time = datetime.utcfromtimestamp(int(data)) except ValueError: - logger.debug("attempting to parse generated lastsync file" - " from mirror %s, value %s" % (url, data)) + # it is bad news to try logging the lastsync value; + # sometimes we get a crazy-encoded web page. + logger.info("attempting to parse generated lastsync file" + " from mirror %s" % url) parsed_time = parse_rfc3339_datetime(data) log.last_sync = parsed_time -- cgit v1.2.3-24-g4f1b