diff options
author | Lars Wirzenius <lwirzenius@wikimedia.org> | 2019-07-23 19:48:07 +0300 |
---|---|---|
committer | Lars Wirzenius <lwirzenius@wikimedia.org> | 2019-07-23 19:48:07 +0300 |
commit | 1d0dd9914b5472525b26bf5c20960b934f32815c (patch) | |
tree | 19caf2bf282b5f37c2f64eed82dc95e73e31a6bd | |
parent | 3b59c01521c8af567fa6467ff324900ca03d30f0 (diff) | |
download | wmf-ci-arch-1d0dd9914b5472525b26bf5c20960b934f32815c.tar.gz |
Change: logging of webhook
-rwxr-xr-x | api.py | 13 |
1 files changed, 5 insertions, 8 deletions
@@ -461,14 +461,11 @@ class Controller(API): r = bottle.request obj = r.json kind = obj.get('object_kind') - if kind == 'build': - fields = [ - 'project_name', - 'build_id', - 'build_status', - ] - for f in fields: - logging.debug('_webhook: %s', obj.get(f)) + r = obj.get('repository') + if kind == 'build' and r is not None: + name = r.get('name') + status = r.get('build_status') + logging.info('Repository %s build status %s', name, status) |