From b657ba10b4290fc464cb39eb6ed2cce8c937da55 Mon Sep 17 00:00:00 2001 From: Derek Schuff Date: Fri, 4 Oct 2024 09:05:09 -0700 Subject: [PATCH] Fix dryrun logic, add it to the missing CI targets --- .github/workflows/w3c-publish.yml | 2 +- document/core/Makefile | 3 ++- document/web-api/Makefile | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/w3c-publish.yml b/.github/workflows/w3c-publish.yml index 561a8e6640..eb190eddc3 100644 --- a/.github/workflows/w3c-publish.yml +++ b/.github/workflows/w3c-publish.yml @@ -54,7 +54,7 @@ jobs: W3C_ECHIDNA_TOKEN_CORE: ${{ secrets.W3C_ECHIDNA_TOKEN_CORE }} W3C_ECHIDNA_TOKEN_JSAPI: ${{ secrets.W3C_ECHIDNA_TOKEN_JSAPI }} W3C_ECHIDNA_TOKEN_WEBAPI: ${{ secrets.W3C_ECHIDNA_TOKEN_WEBAPI }} - ECHIDNA_DRYRUN: ${{ github.event_name == 'pull_request' && github.repository == 'WebAssembly/spec'}} + ECHIDNA_DRYRUN: ${{ !(github.event_name == 'push' && github.repository == 'WebAssembly/spec' && github.ref == 'refs/heads/main') }} - name: Validate all specs with Echidna if: env.W3C_USERNAME run: cd document && make -e WD-echidna diff --git a/document/core/Makefile b/document/core/Makefile index 6943e3e299..49942c71c5 100644 --- a/document/core/Makefile +++ b/document/core/Makefile @@ -214,7 +214,8 @@ WD-echidna-CI: WD-tar curl 'https://labs.w3.org/echidna/api/request' \ -F "tar=@$(BUILDDIR)/WD.tar" \ -F "token=$(W3C_ECHIDNA_TOKEN_CORE)" \ - -F "decision=$(DECISION_URL)" | tee $(BUILDDIR)/WD-echidna-id.txt + -F "decision=$(DECISION_URL)" \ + -F "dry-run=$(ECHIDNA_DRYRUN)" | tee $(BUILDDIR)/WD-echidna-id.txt python3 ../util/check-echidna-status.py $(BUILDDIR) @echo @echo "Published $(W3C_STATUS). Check its status at https://labs.w3.org/echidna/api/status?id=`cat $(BUILDDIR)/WD-echidna-id.txt`" diff --git a/document/web-api/Makefile b/document/web-api/Makefile index bd25da603b..ea018adc56 100644 --- a/document/web-api/Makefile +++ b/document/web-api/Makefile @@ -65,7 +65,8 @@ WD-echidna-CI: WD-tar curl 'https://labs.w3.org/echidna/api/request' \ -F "tar=@$(BUILDDIR)/WD.tar" \ -F "token=$(W3C_ECHIDNA_TOKEN_WEBAPI)" \ - -F "decision=$(DECISION_URL)" | tee $(BUILDDIR)/WD-echidna-id.txt + -F "decision=$(DECISION_URL)" \ + -F "dry-run=$(ECHIDNA_DRYRUN)" | tee $(BUILDDIR)/WD-echidna-id.txt python3 ../util/check-echidna-status.py $(BUILDDIR) @echo @echo "Published $(W3C_STATUS). Check its status at https://labs.w3.org/echidna/api/status?id=`cat $(BUILDDIR)/WD-echidna-id.txt`"