You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by we...@apache.org on 2026/07/28 04:43:27 UTC
(apisix-website) 01/01: fix(ci): stop the docs overlay exiting 1 on a page with no Markdown twin
This is an automated email from the ASF dual-hosted git repository.
moonming pushed a commit to branch fix/overlay-set-e
in repository https://gitbox.apache.org/repos/asf/apisix-website.git
commit fb32e312739e0fc84286598d0b67a30b9e870adf
Author: Ming Wen <we...@apache.org>
AuthorDate: Tue Jul 28 12:43:13 2026 +0800
fix(ci): stop the docs overlay exiting 1 on a page with no Markdown twin
The wave-3 deploy failed in the overlay step. The copy loop ended with
[ -f "$src/$twin" ] && cp "$src/$twin" …
as its last command, so any page without a twin left the pipeline with
exit 1. Under `set -e` that aborted the step — after the files had been
copied, but before a single assertion below it ran. The log shows the
route-manifest check printing its success line and the step dying
immediately after, which is what sent me looking at the canonical
assertion rather than at the loop.
Written as if/fi the loop ends 0 and the assertions execute.
The failure was safe — the step precedes the publish, so asf-site still
holds the previous build — but master has not deployed since wave 3
merged.
---
.github/workflows/deploy.yml | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
index 524e3d3e2a3..974852f5661 100644
--- a/.github/workflows/deploy.yml
+++ b/.github/workflows/deploy.yml
@@ -337,9 +337,14 @@ jobs:
dest="website/build/${locale_prefix}docs/$rel"
mkdir -p "$(dirname "$dest")"
cp "$src/$rel" "$dest"
- # Ship the Markdown twin next to the page it mirrors.
+ # Ship the Markdown twin next to the page it mirrors. Written as
+ # if/fi, not `[ -f … ] && cp …`: the latter is the loop body's
+ # last command, so a page without a twin makes the whole pipeline
+ # exit 1 under `set -e` — silently skipping every assertion below.
twin="${rel%index.html}index.md"
- [ -f "$src/$twin" ] && cp "$src/$twin" "website/build/${locale_prefix}docs/$twin"
+ if [ -f "$src/$twin" ]; then
+ cp "$src/$twin" "website/build/${locale_prefix}docs/$twin"
+ fi
done
done
# The version archives must survive untouched.