]> Frank Brehm's Git Trees - pixelpark/puppetmaster-webhooks.git/commitdiff
Cosmetic changes
authorFrank Brehm <frank.brehm@pixelpark.com>
Wed, 15 Feb 2017 15:06:44 +0000 (16:06 +0100)
committerFrank Brehm <frank.brehm@pixelpark.com>
Wed, 15 Feb 2017 15:06:44 +0000 (16:06 +0100)
lib/webhooks/__init__.py
lib/webhooks/base_app.py
lib/webhooks/r10k.py

index 4dc204c8eea93c77ac19bf72b8787c13e35af9ec..4d4ba826e007ece7b03d3aa81dfa1bc82bcc7396 100644 (file)
@@ -1,6 +1,6 @@
 #!/bin/env python3
 # -*- coding: utf-8 -*-
 
-__version__ = '0.4.7'
+__version__ = '0.4.8'
 
 # vim: ts=4 et list
index 074088d7e26d248a1ceba3e40b72a77bcbb912f2..56e0be137fe3185d402ad92c5815ce4963024c11 100644 (file)
@@ -569,13 +569,17 @@ class BaseHookApp(object):
                 ts_str += '+0000'
             timestamp = datetime.datetime.strptime(ts_str, timeformat)
             email = commit['author']['email']
-            committers.append((timestamp, email))
+            c_name = commit['author']['name']
+            committers.append((timestamp, email, c_name))
 
         if committers:
             committers.sort()
             if self.verbose > 1:
                 LOG.debug("Got committers: {}".format(pp(committers)))
-            self.mail_to_addresses.append(committers[-1][1])
+            last = committers[-1]
+            LOG.info("Last commit by {n!r} <{m}> at {d}.".format(
+                n=last[2], m=last[1], d=last[0].isoformat(' ')))
+            self.mail_to_addresses.append(last[1])
         else:
             LOG.debug("No committers found to append a mail address.")
 
index 5dcfc593141a44b6033fddb0b1e27a02e8b84204..aa9e566c1c06accf76953ea42ede1007f177a6b4 100644 (file)
@@ -100,7 +100,7 @@ class R10kHookApp(BaseHookApp):
             sys.exit(10)
 
         if not os.access(pdir, os.R_OK):
-            LOG.error((
+            LOG.debug((
                 "Directory {!r} is read protected, "
                 "cannot check existence of cert files.").format(pdir))
             return