Release-Upload in CI ohne Fehlerprüfung #62

Open
opened 2026-03-08 18:39:36 +00:00 by automation · 0 comments
Collaborator

Problem

In build-and-release.yml:

curl -s -X POST "${UPLOAD_URL}?name=${NAME}" \
  -H "Authorization: token ${FORGEJO_TOKEN}" ...
  1. curl -s ohne -f — Fehler werden stillschweigend ignoriert
  2. RELEASE_ID wird nicht validiert — wenn curl oder jq fehlschlägt, ist sie leer/null
  3. Upload geht an falsche URL ohne erkennbaren Fehler

Fix

curl -sSf -X POST "$API_URL" ...
RELEASE_ID=$(... | jq -r '.id // empty')
[ -n "$RELEASE_ID" ] && [ "$RELEASE_ID" != "null" ] || { echo "ERROR: Release creation failed"; exit 1; }

Gefunden von

Duft

## Problem In `build-and-release.yml`: ```bash curl -s -X POST "${UPLOAD_URL}?name=${NAME}" \ -H "Authorization: token ${FORGEJO_TOKEN}" ... ``` 1. `curl -s` ohne `-f` — Fehler werden stillschweigend ignoriert 2. `RELEASE_ID` wird nicht validiert — wenn `curl` oder `jq` fehlschlägt, ist sie leer/null 3. Upload geht an falsche URL ohne erkennbaren Fehler ### Fix ```bash curl -sSf -X POST "$API_URL" ... RELEASE_ID=$(... | jq -r '.id // empty') [ -n "$RELEASE_ID" ] && [ "$RELEASE_ID" != "null" ] || { echo "ERROR: Release creation failed"; exit 1; } ``` ## Gefunden von Duft
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
ai-tools/jdt-mcp-server#62
No description provided.