-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Renovate failing to make PR on Gitea 1.16.1 #14059
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
Comments
Hi there, Help us by making a minimal reproduction repository. Before we can start work on your issue we first need to know exactly what's causing the current behavior. A minimal reproduction helps us with this. To get started, please read our guide on creating a minimal reproduction to understand what is needed. We may close the issue if you (or someone else) have not provided a minimal reproduction within two weeks. If you need more time, or are stuck, please ask for help or more time in a comment. Good luck, The Renovate team |
Renovate works fine with many other instances of Gitea, so unfortunately you will need to do some reproducing/troubleshooting if we are to understand what's going wrong with yours. |
When you say:
What changed? Gitea version, or Renovate version? |
I upgraded Gitea to 1.16.0 and then to 1.16.1. It worked prior to the 1.16.0 upgrade but ceased to work since then. Renovate version is continually updated according to the |
In this case we don't know if it's a Gitea change or Renovate change so need to wait for further feedback |
I don't see any issues on my gitea instance |
Appears to be an upstream issue with Gtea rather than issue with Renovate. The permissions system was changed in 1.16.0 leading to the wrong value "read-only" being returned by Renovate's permission checks, rather than "read-write". Currently, the only way to fix this is to add the Renovate user to a team with "Administrator Access" to repositories. |
I'm facing the same issue. @redstonedesigner is there an existing Gitea issue already? |
The strange thing is, it is still working on other repos on the same Gitea (v1.16.1) server. So the current operation is:
The described workaround does not fix the issue for me, and due to the fact that everything works on other repos this does not look like a gitea or permission issue to me. @viceice @rarkins Would you mind reopening the issue, or should I create a new one? Thanks for your help. |
I don't believe there is currently an open issue for this on Gitea. |
Open a new bug report with an exact reproduction. So it's probably a PR body issue. |
The old code generates `structs.Repository.Permissions` with only `access.Permission.AccessMode`, however, it should check the units too, or the value could be incorrect. For example, `structs.Repository.Permissions.Push` could be false even the doer has write access to code unit. Should fix renovatebot/renovate#14059 (comment) (Not reported by it, I just found it when I was looking into this bug) --- Review tips: The major changes are - `modules/structs/repo.go` https://github.com/go-gitea/gitea/pull/25388/files#diff-870406f6857117f8b03611c43fca0ab9ed6d6e76a2d0069a7c1f17e8fa9092f7 - `services/convert/repository.go` https://github.com/go-gitea/gitea/pull/25388/files#diff-7736f6d2ae894c9edb7729a80ab89aa183b888a26a811a0c1fdebd18726a7101 And other changes are passive.
The old code generates `structs.Repository.Permissions` with only `access.Permission.AccessMode`, however, it should check the units too, or the value could be incorrect. For example, `structs.Repository.Permissions.Push` could be false even the doer has write access to code unit. Should fix renovatebot/renovate#14059 (comment) (Not reported by it, I just found it when I was looking into this bug) --- Review tips: The major changes are - `modules/structs/repo.go` https://github.com/go-gitea/gitea/pull/25388/files#diff-870406f6857117f8b03611c43fca0ab9ed6d6e76a2d0069a7c1f17e8fa9092f7 - `services/convert/repository.go` https://github.com/go-gitea/gitea/pull/25388/files#diff-7736f6d2ae894c9edb7729a80ab89aa183b888a26a811a0c1fdebd18726a7101 And other changes are passive.
Backport #25388 by @wolfogre The old code generates `structs.Repository.Permissions` with only `access.Permission.AccessMode`, however, it should check the units too, or the value could be incorrect. For example, `structs.Repository.Permissions.Push` could be false even the doer has write access to code unit. Should fix renovatebot/renovate#14059 (comment) (Not reported by it, I just found it when I was looking into this bug) --- Review tips: The major changes are - `modules/structs/repo.go` https://github.com/go-gitea/gitea/pull/25388/files#diff-870406f6857117f8b03611c43fca0ab9ed6d6e76a2d0069a7c1f17e8fa9092f7 - `services/convert/repository.go` https://github.com/go-gitea/gitea/pull/25388/files#diff-7736f6d2ae894c9edb7729a80ab89aa183b888a26a811a0c1fdebd18726a7101 And other changes are passive. Co-authored-by: Jason Song <[email protected]>
this is now fixed upstream in v1.20.0 |
How are you running Renovate?
Self-hosted
If you're self-hosting Renovate, tell us what version of Renovate you run.
31.68.0
Please select which platform you are using if self-hosting.
Gitea
If you're self-hosting Renovate, tell us what version of the platform you run.
1.16.1
Was this something which used to work for you, and then stopped?
It used to work, and then stopped
Describe the bug
When attempting to post a Pull Request to a repository, there is a 422 Unprocessable Entity returned by Gitea to Renovate. This seems to be due to a malformed JSON input from Renovate to Gitea.
Relevant debug logs
Logs
The text was updated successfully, but these errors were encountered: