]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
Add teuthology branch to sentry report tags 87/head
authorZack Cerza <zack@cerza.org>
Wed, 11 Sep 2013 20:45:45 +0000 (15:45 -0500)
committerZack Cerza <zack@cerza.org>
Wed, 11 Sep 2013 20:45:45 +0000 (15:45 -0500)
teuthology/run_tasks.py

index 7a532f5f25cbcf2a5c6e4dac6dc96b6092611c90..fa47541bbd45f914f745dd0ad422bc26aeee77c9 100644 (file)
@@ -39,19 +39,22 @@ def run_tasks(tasks, ctx):
         log.exception('Saw exception from tasks.')
         sentry = get_sentry_client()
         if sentry:
+            config = deepcopy(ctx.config)
+
             tags = {
                 'task': taskname,
                 'owner': ctx.owner,
             }
-            job_id = getattr(ctx, 'job_id', None)
+            if 'teuthology_branch' in config:
+                tags['teuthology_branch'] = config['teuthology_branch']
 
-            config = deepcopy(ctx.config)
             # Remove ssh keys from reported config
             if 'targets' in config:
                 targets = config['targets']
                 for host in targets.keys():
                     targets[host] = '<redacted>'
 
+            job_id = getattr(ctx, 'job_id', None)
             extra = {
                 'config': config,
                 'logs': get_http_log_path(ctx.archive, job_id),