The PR creation curl immediately follows branch creation via the Contents
API, but Gitea may not have fully indexed the new branch for pull request
operations yet. This causes intermittent HTTP errors on the first run.
- Add sleep 3 before PR creation to allow Gitea to process the new branch
- Use --retry-all-errors so curl retries on HTTP 4xx/5xx (not just
connection failures)
- Capture and display the actual HTTP error code and response body on
failure for easier debugging
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>