-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Fix api error message if fork exists (#24487) #24493
Merged
techknowlogick
merged 3 commits into
go-gitea:release/v1.19
from
GiteaBot:backport-24487-v1.19
May 3, 2023
Merged
Fix api error message if fork exists (#24487) #24493
techknowlogick
merged 3 commits into
go-gitea:release/v1.19
from
GiteaBot:backport-24487-v1.19
May 3, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…o-gitea#24485) Backport go-gitea#24444 by @silverwind Remove the [renderWhitespace](https://microsoft.github.io/monaco-editor/docs.html#interfaces/editor.IEditorOptions.html#renderWhitespace) override, so the default value of `selection` takes over and makes whitespace visible on selection. <img width="128" alt="Screenshot 2023-04-30 at 19 09 41" src="https://user-images.githubusercontent.com/115237/235366707-d598268d-03cc-4839-a195-c460bddae99b.png"> Co-authored-by: silverwind <me@silverwind.io>
On the @forgejo instance of Codeberg, we discovered that forking a repo which is already forked now returns a 500 Internal Server Error, which is unexpected. This is an attempt at fixing this. The error message in the log: ~~~ 2023/05/02 08:36:30 .../api/v1/repo/fork.go:147:CreateFork() [E] [6450cb8e-113] ForkRepository: repository is already forked by user [uname: ...., repo path: .../..., fork path: .../...] ~~~ The service that is used for forking returns a custom error message which is not checked against. About the order of options: The case that the fork already exists should be more common, followed by the case that a repo with the same name already exists for other reasons. The case that the global repo limit is hit is probably not the likeliest. Co-authored-by: Otto Richter <otto@codeberg.org> Co-authored-by: Giteabot <teabot@gitea.io>
GiteaBot
added
the
lgtm/need 2
This PR needs two approvals by maintainers to be considered for merging.
label
May 3, 2023
pull-request-size
bot
added
the
size/XS
Denotes a PR that changes 0-9 lines, ignoring generated files.
label
May 3, 2023
jolheiser
approved these changes
May 3, 2023
GiteaBot
added
lgtm/need 1
This PR needs approval from one additional maintainer to be merged.
and removed
lgtm/need 2
This PR needs two approvals by maintainers to be considered for merging.
labels
May 3, 2023
techknowlogick
force-pushed
the
release/v1.19
branch
from
May 3, 2023 02:41
2f1ff2d
to
499257d
Compare
delvh
approved these changes
May 3, 2023
GiteaBot
added
lgtm/done
This PR has enough approvals to get merged. There are no important open reservations anymore.
and removed
lgtm/need 1
This PR needs approval from one additional maintainer to be merged.
labels
May 3, 2023
delvh
added
the
reviewed/wait-merge
This pull request is part of the merge queue. It will be merged soon.
label
May 3, 2023
Merged
Merge it so we can release 1.19.3 |
GiteaBot
removed
the
reviewed/wait-merge
This pull request is part of the merge queue. It will be merged soon.
label
May 3, 2023
Sh4kE
added a commit
to Sh4kE/k8s-projects
that referenced
this pull request
May 7, 2023
This PR contains the following updates: | Package | Update | Change | |---|---|---| | [gitea/gitea](https://github.com/go-gitea/gitea) | patch | `1.19.2-rootless` -> `1.19.3-rootless` | --- ### Release Notes <details> <summary>go-gitea/gitea</summary> ### [`v1.19.3`](https://github.com/go-gitea/gitea/blob/HEAD/CHANGELOG.md#​1193-httpsgithubcomgo-giteagiteareleasestag1193---2023-05-03) [Compare Source](go-gitea/gitea@v1.19.2...v1.19.3) - SECURITY - Use golang 1.20.4 to fix CVE-2023-24539, CVE-2023-24540, and CVE-2023-29400 - ENHANCEMENTS - Enable whitespace rendering on selection in Monaco ([#​24444](go-gitea/gitea#24444)) ([#​24485](go-gitea/gitea#24485)) - Improve milestone filter on issues page ([#​22423](go-gitea/gitea#22423)) ([#​24440](go-gitea/gitea#24440)) - BUGFIXES - Fix api error message if fork exists ([#​24487](go-gitea/gitea#24487)) ([#​24493](go-gitea/gitea#24493)) - Fix user-cards format ([#​24428](go-gitea/gitea#24428)) ([#​24431](go-gitea/gitea#24431)) - Fix incorrect CurrentUser check for docker rootless ([#​24435](go-gitea/gitea#24435)) - Getting the tag list does not require being signed in ([#​24413](go-gitea/gitea#24413)) ([#​24416](go-gitea/gitea#24416)) </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNS42Ni4zIiwidXBkYXRlZEluVmVyIjoiMzUuNjYuMyIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==--> Co-authored-by: Michael Wittig <michael.wittig@posteo.de> Reviewed-on: https://gitea.sh4ke.rocks/sh4ke/k8s-projects/pulls/178
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Backport #24487 by @fnetX
On the @forgejo instance of Codeberg, we discovered that forking a repo which is already forked now returns a 500 Internal Server Error, which is unexpected. This is an attempt at fixing this.
The error message in the log:
The service that is used for forking returns a custom error message which is not checked against.
About the order of options:
The case that the fork already exists should be more common, followed by the case that a repo with the same name already exists for other reasons. The case that the global repo limit is hit is probably not the likeliest.