From 18d970b70e00d76b9e80db6499e8c3f9dd72a59d Mon Sep 17 00:00:00 2001 From: Aleksandr Neychev Date: Fri, 14 Aug 2026 04:51:19 +0500 Subject: [PATCH] add a probe workflow for the artifact upload The release takes four minutes to reach the upload and fails there on a check the action makes before any request leaves the runner. The probe asks the same questions in seconds: what the runner puts in the GITHUB_ names, whether a step-level env reaches a JS action at all, and which of v3 and v4 gets an artifact through. Co-Authored-By: Claude Opus 5 (1M context) --- .gitea/workflows/probe-artifacts.yml | 70 ++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 .gitea/workflows/probe-artifacts.yml diff --git a/.gitea/workflows/probe-artifacts.yml b/.gitea/workflows/probe-artifacts.yml new file mode 100644 index 0000000..82d4ef9 --- /dev/null +++ b/.gitea/workflows/probe-artifacts.yml @@ -0,0 +1,70 @@ +# A throwaway workflow: it answers, in one run, what the release cannot ask +# without building for four minutes first. +# +# Three questions. Whether a step-level env reaches a JS action at all or the +# runner overwrites the GITHUB_ names with its own; whether this Gitea speaks +# the v4 artifact protocol (ACTIONS_RESULTS_URL is the giveaway); and whether +# the v3 action still gets its artifact through. Every upload is allowed to +# fail, so a single run reports on all three rather than stopping at the first. +# +# Delete this file once the release works +name: Probe the artifacts + +on: + workflow_dispatch: + push: + branches: + - 'probe/**' + +defaults: + run: + shell: pwsh + +jobs: + probe: + runs-on: windows-x64 + + steps: + - name: Make a file to upload + run: | + New-Item -ItemType Directory -Force probe | Out-Null + 'probe' | Out-File probe/probe.txt -Encoding utf8 + + # What the runner hands out on its own + - name: Show the environment as it comes + run: | + "server = [$env:GITHUB_SERVER_URL]" + "api = [$env:GITHUB_API_URL]" + "results= [$env:ACTIONS_RESULTS_URL]" + "runtime= [$env:ACTIONS_RUNTIME_URL]" + + # The same, with the substitution the release step makes. A run step is + # not a JS action, but if the name is overwritten even here, the answer is + # settled and nothing in the workflow can set it + - name: Show the environment with the substitution + env: + GITHUB_SERVER_URL: https://github.com + run: '"server = [$env:GITHUB_SERVER_URL]"' + + - name: Upload with v4, plain + continue-on-error: true + uses: actions/upload-artifact@v4 + with: + name: probe-v4-plain + path: probe/ + + - name: Upload with v4 and the substitution + continue-on-error: true + uses: actions/upload-artifact@v4 + env: + GITHUB_SERVER_URL: https://github.com + with: + name: probe-v4-substituted + path: probe/ + + - name: Upload with v3 + continue-on-error: true + uses: actions/upload-artifact@v3 + with: + name: probe-v3 + path: probe/