Stop double-logging the build id

There is a logging adapter that preprends the job id to log lines, so
putting it into the message as well is duplication. This should turn
this:

  2017-07-27 19:45:00,836 DEBUG zuul.AnsibleJob: [build:
68c5833049c34d4c9e564811c43ad303] Job 68c5833049c34d4c9e564811c43ad303:
git updates complete

into:

  2017-07-27 19:45:00,836 DEBUG zuul.AnsibleJob: [build:
68c5833049c34d4c9e564811c43ad303] Git updates complete

Change-Id: I5e25510d87f195f4f241a83d8faf6515232c6b4d
changes/83/488183/2
Monty Taylor 5 years ago
parent ae1f03a9f5
commit e16e6481e1
No known key found for this signature in database
GPG Key ID: 7BAE94BC7141A594
  1. 8
      zuul/executor/server.py

@ -812,8 +812,7 @@ class AnsibleJob(object):
# Make sure all projects used by the job are updated...
for project in args['projects']:
self.log.debug("Job %s: updating project %s" %
(self.job.unique, project))
self.log.debug("Updating project %s" % (project,))
tasks.append(self.executor_server.update(
project['connection'], project['name']))
projects.add((project['connection'], project['name']))
@ -827,8 +826,7 @@ class AnsibleJob(object):
repos += playbook['roles']
for repo in repos:
self.log.debug("Job %s: updating playbook or role %s" %
(self.job.unique, repo))
self.log.debug("Updating playbook or role %s" % (repo,))
key = (repo['connection'], repo['project'])
if key not in projects:
tasks.append(self.executor_server.update(*key))
@ -837,7 +835,7 @@ class AnsibleJob(object):
for task in tasks:
task.wait()
self.log.debug("Job %s: git updates complete" % (self.job.unique,))
self.log.debug("Git updates complete")
merger = self.executor_server._getMerger(self.jobdir.src_root,
self.log)
repos = {}

Loading…
Cancel
Save