Landing blocker for #61 and #63: the deployment checkout is 12 commits behind and `merge --ff-only` refuses while tracked paths are dirty. Discard is not available here (workspace policy: no `checkout`/`stash` on shared state), so the dirt is committed. - `agent/APPEND_SYSTEM.md`: the point-of-use / one-work-log / PR-link doctrine, already byte-identical to `origin/main` (`cmp` against the trunk blob: no difference). No new prose — the commit exists so the trunk merge can proceed. - `agent/config.yml` and `agent/managed-skills/**`: the machine-live tier the heartbeat owns (AGENTS.md § Live-sync tiers). `ALLOW_SECRETS=1` was used, deliberately and after auditing the staged diff by hand: the only credential-shaped strings in it are two copies of `AKIA0000000000000EXAMPLE` — the inert all-zero AWS example id — and they appear inside the two skill pages that teach that exact placeholder shape. This checkout is still running the pre-#61 hook; the merged gate (value-scoped placeholder filter, `71601f7`) exempts this value, so the refusal dies with this landing. No `--no-verify` was used: the gate ran and its verdict is recorded here. Refs #61
1.5 KiB
1.5 KiB
name, description
| name | description |
|---|---|
| gitea-merge-form-encoded | Merge a Dankclaw Gitea PR with form-encoded do=merge — and the two body failures: 422 [Do]: Required (JSON body) and jsontext invalid character 'd' (form body with Content-Type: application/json header). |
Gitea merge on Dankclaw: form-encoded, and nothing else
POST /api/v1/repos/<owner>/<repo>/pulls/<n>/merge with -d 'do=merge&merge_style=no-ff'.
The two body failures
- JSON body →
422 {"message":"[Do]: Required"}. The endpoint reads FORM fields, not JSON. - Form body but a
Content-Type: application/jsonheader (e.g. left over in the curl-Kconfig file from an earlier PR-body PATCH on the same request setup) →422 {"message":"[]: jsontext: invalid character 'd' at start of value"}— Gitea tries to parsedo=merge...as JSON.
Working pattern
Keep TWO curl config files when a session both patches PR bodies (JSON) and merges (form):
# merge.cfg — auth ONLY, no Content-Type
header = "Authorization: token $TOKEN"
curl -s -K merge.cfg -X POST -d 'do=merge&merge_style=no-ff' http://192.168.0.143:3000/api/v1/repos/<o>/<r>/pulls/<n>/merge
- Success = HTTP 200 with an empty body; verify by landing a checkout (
git ls-remote origin main), never by re-reading the PR. - PATCH
/pulls/<n>(title/body) is the opposite: JSON body WITH the Content-Type header. - Token from
~/.config/secrets/giteavia a 600-perm-Kfile, never-H(/proc/<pid>/cmdlineis world-readable).