Fix result upload: 422 on PowerShell 5.1 #6
Loading…
Reference in a new issue
No description provided.
Delete branch "fix-pr-upload-422"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Every pending result failed to upload with
(422) Unprocessable Entity(seen on PC-003, retrying PC-001/002/003 runs).Cause. On Windows PowerShell 5.1,
Get-Content -Rawreturns a string tagged with PSPath etc., andConvertTo-Json -Depth 4sends the PRbodyas an object. Forgejo:json: cannot unmarshal object into Go struct field CreatePullRequestOption.body of type string. The branch push before it worked, so the result branches already exist in theinventory-botfork.Fix
title.txt/summary.mdwith[IO.File]::ReadAllText(..., UTF8)(they are written withWriteAllTextUTF-8).pull request already exists ... issue_id: N(409; PC-001_20261104-132244 already has #4), count it as uploaded and return that PR's URL, so it leavespending\.$InvVersion->2026.11.04.4.Checks
body; the 409 message checked against the server and the regex.workbench validate: fails in workbench's own skill-link self-tests (tests/ensure-test.sh, 22 checks); it does not check this repo's files.Review-gate: gpt-6.1-sol ship (Gate 1 skipped: small fix). Nits not taken: a fallback that reads the response stream when ErrorDetails is empty (fails safe today: it rethrows and the result stays in pending).
🤖 Generated with Claude Code
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.