Module: Mesa Branch: staging/21.1 Commit: ceafcf3daf20763795bda6a9f166443bd84b7bf4 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=ceafcf3daf20763795bda6a9f166443bd84b7bf4
Author: Erik Faye-Lund <[email protected]> Date: Thu Apr 22 13:46:41 2021 +0200 docs: do not generate redirects on error The build-finished event is also triggered when there's an error. I somehow got the second argument wrong, and ended up ignoring the case. This can lead to new exceptions being thrown due to missing files, that ends up hiding the real problem. Fixes: 64a4ba9e1ce ("docs: add an extension to generate redirects") Reviewed-by: Eric Engestrom <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10407> (cherry picked from commit 2736370294427d87933ce7ae293e0465fbab77e2) --- .pick_status.json | 2 +- docs/_exts/redirects.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index 5c94e713e65..8abe3f562b0 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -220,7 +220,7 @@ "description": "docs: do not generate redirects on error", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "master_sha": null, "because_sha": "64a4ba9e1ceeccbc7adeae368b5bc2553be88610" }, diff --git a/docs/_exts/redirects.py b/docs/_exts/redirects.py index 90d69efee5f..1adf3cdb8ab 100644 --- a/docs/_exts/redirects.py +++ b/docs/_exts/redirects.py @@ -6,8 +6,8 @@ def create_redirect(dst): tpl = '<html><head><meta http-equiv="refresh" content="0; url={0}"><script>window.location.replace("{0}")</script></head></html>' return tpl.format(dst) -def create_redirects(app, docname): - if not app.builder.name == 'html': +def create_redirects(app, exception): + if exception is not None or not app.builder.name == 'html': return for src, dst in app.config.html_redirects: path = os.path.join(app.outdir, '{0}.html'.format(src)) _______________________________________________ mesa-commit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-commit
