Skip to content

Allow to move project repositories in hidden/pending_delete state

What does this MR do and why?

Contributes to https://gitlab.com/gitlab-org/gitlab/-/issues/430064

Problem

It's not possible to move projects in hidden/pending_delete state by the admin. That blocks the Gitaly migration.

Solution

Permit to schedule project moves for hidden/pending_delete projects.

Screenshots or screen recordings

Before After
Screenshot_2023-11-02_at_10.49.28 Screenshot_2023-11-02_at_10.50.02

How to set up and validate locally

  1. Open Rails console
  2. Temporary mark the project as hidden Project.last.update(hidden: true)
  3. Visit http://127.0.0.1:3000/api/v4/projects/<project_id>/repository_storage_moves page as an admin
  4. You should see a list of repository storage moves (most probably just an empty array)
  5. Switch to master branch
  6. Visit http://127.0.0.1:3000/api/v4/projects/<project_id>/repository_storage_moves page as an admin
  7. You should see Project not found error

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Vasilii Iakliushin

Merge request reports