actions logs on Forgejo: read job logs from the web route when the jobs API is missing #506

Open
opened 2026-09-15 21:44:31 +00:00 by hexajon · 0 comments
Owner

What happens

madt_actions documents jobs, job_get, and job_logs as Gitea-only. That matches the live servers on 2026-09-15:

  • Gitea 1.27.3: GET /repos/{owner}/{repo}/actions/runs/{id}/jobs returns the run's job (name, status completed, conclusion failure).
  • Forgejo 15.0.6: GET /repos/sixfold-space/madtea/actions/runs/263/jobs returns 404.

So on Forgejo, madtea tells me a run failed but cannot tell me why. Today I found which gate step and which test case failed only by fetching the web route:

GET https://git.cheshirecube.cloud/sixfold-space/madtea/actions/runs/<n>/jobs/<j>/attempt/<a>/logs

It returned the plain-text job log (HTTP 200) with no auth, for a public repo. <n> is the web run number (index_in_repo), not the API id. /actions/runs/<n> without the job and attempt redirects (307) to /jobs/0/attempt/1.

Ask

  • On Forgejo, job_logs (and a way to list a run's jobs) fall back to the web route.
  • Map the API id to index_in_repo for the URL.
  • Find out whether the route accepts token auth for a private repo. I only tested a public repo without auth.
  • Record the result in docs/COMPAT.md.

Acceptance

  • On Forgejo, one madtea call returns a failed job's log for a public repo.
  • The private-repo behaviour is known and documented.
## What happens `madt_actions` documents `jobs`, `job_get`, and `job_logs` as Gitea-only. That matches the live servers on 2026-09-15: - Gitea 1.27.3: `GET /repos/{owner}/{repo}/actions/runs/{id}/jobs` returns the run's job (name, status `completed`, conclusion `failure`). - Forgejo 15.0.6: `GET /repos/sixfold-space/madtea/actions/runs/263/jobs` returns 404. So on Forgejo, madtea tells me a run failed but cannot tell me why. Today I found which gate step and which test case failed only by fetching the web route: ``` GET https://git.cheshirecube.cloud/sixfold-space/madtea/actions/runs/<n>/jobs/<j>/attempt/<a>/logs ``` It returned the plain-text job log (HTTP 200) with no auth, for a public repo. `<n>` is the web run number (`index_in_repo`), not the API id. `/actions/runs/<n>` without the job and attempt redirects (307) to `/jobs/0/attempt/1`. ## Ask - On Forgejo, `job_logs` (and a way to list a run's jobs) fall back to the web route. - Map the API id to `index_in_repo` for the URL. - Find out whether the route accepts token auth for a private repo. I only tested a public repo without auth. - Record the result in `docs/COMPAT.md`. ## Acceptance - On Forgejo, one madtea call returns a failed job's log for a public repo. - The private-repo behaviour is known and documented.
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
sixfold-space/madtea#506
No description provided.