diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-18 11:17:02 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-18 11:17:02 +0300 |
commit | b39512ed755239198a9c294b6a45e65c05900235 (patch) | |
tree | d234a3efade1de67c46b9e5a38ce813627726aa7 /lib/gitlab/git/repository.rb | |
parent | d31474cf3b17ece37939d20082b07f6657cc79a9 (diff) |
Add latest changes from gitlab-org/gitlab@15-3-stable-eev15.3.0-rc42
Diffstat (limited to 'lib/gitlab/git/repository.rb')
-rw-r--r-- | lib/gitlab/git/repository.rb | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/lib/gitlab/git/repository.rb b/lib/gitlab/git/repository.rb index d7f892ae9d9..ad655fedb6d 100644 --- a/lib/gitlab/git/repository.rb +++ b/lib/gitlab/git/repository.rb @@ -135,6 +135,13 @@ module Gitlab gitaly_ref_client.find_tag(name) end rescue CommandError + # Gitaly used to return an `Internal` error in case the tag wasn't found, which is being translated to + # `CommandError` by the wrapper. This has been converted in v15.3.0 to instead return a structured + # error with a `tag_not_found` error, so rescuing from `Internal` errors can be removed in v15.4.0 and + # later. + rescue Gitlab::Git::UnknownRef + # This is the new error returned by `find_tag`, which knows to translate the structured error returned + # by Gitaly when the tag does not exist. end def local_branches(sort_by: nil, pagination_params: nil) @@ -910,7 +917,7 @@ module Gitlab def multi_action( user, branch_name:, message:, actions:, author_email: nil, author_name: nil, - start_branch_name: nil, start_sha: nil, start_repository: self, + start_branch_name: nil, start_sha: nil, start_repository: nil, force: false) wrapped_gitaly_errors do @@ -930,6 +937,12 @@ module Gitlab gitaly_repository_client.set_full_path(full_path) end + def full_path + wrapped_gitaly_errors do + gitaly_repository_client.full_path + end + end + def disconnect_alternates wrapped_gitaly_errors do gitaly_repository_client.disconnect_alternates |