From 43a8e34559e594a33faafecfe9a0a33e52e25ee8 Mon Sep 17 00:00:00 2001 From: "James E. Blair" Date: Fri, 16 Jul 2021 15:54:41 -0700 Subject: [PATCH] Don't display in-progress builds/buildsets in the web listing The main purpose of the build and buildset listings is to find completed builds, not in-progress builds (that's the status page), so when we query the Zuul API, always set "completed=true". In the future, it might be nice to list in-progress builds on these pages, but that will require significantly more UI work to add it to the filter bar. Additionally, update the buildset page to show in-progress builds. It currently doesn't because it assumes all non-final builds are retry attemtps and therefore stores them under a secondary key. That's no longer true, and additionally, completed retried builds now have an explicit "RETRY" result which makes them easy for users to distinguish. It's more useful for a user to be able to see that a buildset is still in progress and also the retried builds (now that we store all of them), so this change returns all the builds of a buildset. Change-Id: I83d89c2903e6fd0aaf67c66f61d106b2c5db3797 --- web/src/containers/FilterToolbar.jsx | 2 +- zuul/web/__init__.py | 7 +------ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/web/src/containers/FilterToolbar.jsx b/web/src/containers/FilterToolbar.jsx index f1277a4414..dcb7c4c437 100644 --- a/web/src/containers/FilterToolbar.jsx +++ b/web/src/containers/FilterToolbar.jsx @@ -233,7 +233,7 @@ function writeFiltersToUrl(filters, location, history) { } function buildQueryString(filters) { - let queryString = '' + let queryString = '&complete=true' if (filters) { Object.keys(filters).map((key) => { filters[key].forEach((value) => { diff --git a/zuul/web/__init__.py b/zuul/web/__init__.py index 8b62a0e0be..8d4df25d18 100755 --- a/zuul/web/__init__.py +++ b/zuul/web/__init__.py @@ -1037,13 +1037,8 @@ class ZuulWebAPI(object): } if builds: ret['builds'] = [] - ret['retry_builds'] = [] for build in builds: - # Put all non-final (retry) builds under a different key - if not build.final: - ret['retry_builds'].append(self.buildToDict(build)) - else: - ret['builds'].append(self.buildToDict(build)) + ret['builds'].append(self.buildToDict(build)) return ret @cherrypy.expose