diff options
author | David G. Quintas <dgq@google.com> | 2017-09-08 11:44:19 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-08 11:44:19 -0700 |
commit | 24ea59b31de83fadced949a558b8eda44c3bff35 (patch) | |
tree | 6bdc12850baff337e36477c023cbc32808e6d4fe | |
parent | a87f22d1ab8444cc56a1df0518355023d0bc8ec9 (diff) | |
parent | 38a83b3c40fb44fc781098815efa201da2a7d904 (diff) |
Merge pull request #12447 from dgquintas/detect_flakes_print_url
Print kokoro URL for new flakes
-rw-r--r-- | tools/flakes/detect_flakes.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/flakes/detect_flakes.py b/tools/flakes/detect_flakes.py index 2aff4c0872..c5c7f61771 100644 --- a/tools/flakes/detect_flakes.py +++ b/tools/flakes/detect_flakes.py @@ -33,14 +33,17 @@ sys.path.append(gcp_utils_dir) import big_query_utils def print_table(table): - for i, (k, v) in enumerate(table.items()): + kokoro_base_url = 'https://kokoro.corp.google.com/job/' + for k, v in table.items(): job_name = v[0] build_id = v[1] ts = int(float(v[2])) # TODO(dgq): timezone handling is wrong. We need to determine the timezone # of the computer running this script. human_ts = datetime.datetime.utcfromtimestamp(ts).strftime('%Y-%m-%d %H:%M:%S PDT') - print("{}. Test: {}, Timestamp: {}, id: {}@{}\n".format(i, k, human_ts, job_name, build_id)) + job_path = '{}/{}'.format('/job/'.join(job_name.split('/')), build_id) + full_kokoro_url = kokoro_base_url + job_path + print("Test: {}, Timestamp: {}, url: {}\n".format(k, human_ts, full_kokoro_url)) def get_flaky_tests(days_lower_bound, days_upper_bound, limit=None): |