-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong usage of Gitea API for fetching head branch name #6018
Comments
Further documentation is here: https://github.com/go-gitea/gitea/blob/bb4261a5ed678235fadef279fe1ba1505993a406/templates/swagger/v1_json.tmpl#L12804 The tests on Gitea side can be seen here https://github.com/go-gitea/gitea/blob/5abe1c52de533b52725b1e584db9fea6fb1b39ab/modules/convert/pull_test.go#L25 As well as actual implementation here: https://github.com/go-gitea/gitea/blob/3fc4f3670cb748e02d786111d2029ef1e23a9640/modules/convert/pull.go#L72 (for existing branches, |
@proton-ab thanks for the fix! |
🎉 This issue has been resolved in version 19.216.3 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
What Renovate type are you using?
Self-hosted, Gitea.
Describe the bug
Renovate looks up at
ref
in order to fetch the name of head branch for Gitea PR, however that field will point to unnamed reference when branch is removed.Did you see anything helpful in debug logs?
No
To Reproduce
Using Gitea 1.12 as of commit 3d7d828a35dc187ae56c62fc438715d3dee78f3f
Additional context
Gitea added ability for deleted branches names to be retained in go-gitea/gitea#10413, this issue affects only Gitea versions >= 1.12.
Gitea API exposes two fields of interest for Renovate for head branch on PR -
ref
andlabel
. Usually when PR is open and branch exist, both of them contain same information - branch name. When PR is closed and branch removed,label
still contains the correct branch name, whileref
points at unnamed reference within Git repository.I have opened PR to fix this in #5998, this issue is for tracking purposes only.
The text was updated successfully, but these errors were encountered: