14.6.0 Deleting projects fails
Summary
Version: 14.6.0, downloaded from https://hub.docker.com/r/gitlab/gitlab-ee
GitLab fails to remove deleted projects.
Steps to reproduce
Project X -> Settings -> General -> Advanced -> Delete project An banner pops up showing that the project will be deleted.
What is the current bug behavior?
The project does not get deleted. Best case is that the repository is removed. The project then remains active as "empty shell" still showing up everywhere just like a regular project. When clicking on that project it says "No Repository The repository for this projec does not exist. This means you can not push code until you create an empty repository or import an existing one" Next to it there is a "[Create empty repository] or [Import repository]" If I click [Create empty repository] I can add files. It says at the top that the project was scheduled for deletion but could not be deleted because the repository was not found. Even with the new repository now the project cannot be deleted. The project remains in the list of projects, clicking on it now gives error 500.
What is the expected correct behavior?
The project should be deleted including its repository. It should not be visible anymore in GitLab after a few minutes.
Relevant logs
Relevant logs
Deletion of the project project1-build-images in Group project1gitlab.1.9waaf52jzavk@nreesv19 | ==> /var/log/gitlab/gitlab-rails/production.log <== gitlab.1.9waaf52jzavk@nreesv19 | Started DELETE "/project1/project1-build-images" for W.X.Y.Z at 2022-01-24 12:37:29 +0000 gitlab.1.9waaf52jzavk@nreesv19 | Processing by ProjectsController#destroy as HTML gitlab.1.9waaf52jzavk@nreesv19 | Parameters: {"authenticity_token"=>"[FILTERED]", "namespace_id"=>"project1", "id"=>"project1-build-images"} gitlab.1.9waaf52jzavk@nreesv19 | Redirected to https://gitlab.foo.bar/dashboard/projects gitlab.1.9waaf52jzavk@nreesv19 | Completed 302 Found in 108ms (ActiveRecord: 47.9ms | Elasticsearch: 0.0ms | Allocations: 30791) gitlab.1.9waaf52jzavk@nreesv19 | Started GET "/dashboard/projects" for W.X.Y.Z at 2022-01-24 12:37:30 +0000 gitlab.1.9waaf52jzavk@nreesv19 | Processing by Dashboard::ProjectsController#index as HTML gitlab.1.9waaf52jzavk@nreesv19 | Rendered layout layouts/dashboard.html.haml (Duration: 152.6ms | Allocations: 80649) gitlab.1.9waaf52jzavk@nreesv19 | Completed 200 OK in 208ms (Views: 121.8ms | ActiveRecord: 38.8ms | Elasticsearch: 0.0ms | Allocations: 106491) gitlab.1.9waaf52jzavk@nreesv19 | gitlab.1.9waaf52jzavk@nreesv19 | ==> /var/log/gitlab/gitlab-rails/application.log <== gitlab.1.9waaf52jzavk@nreesv19 | 2022-01-24T12:37:30.024Z: User 2 scheduled destruction of project project1/project1-build-images with job ID 68d06ef7881b332d4e6099a9 gitlab.1.9waaf52jzavk@nreesv19 | 2022-01-24T12:37:30.083Z: Attempting to destroy project1/project1-build-images (99) gitlab.1.9waaf52jzavk@nreesv19 | 2022-01-24T12:37:30.122Z: Repository "@hashed/8c/1f/8c1f1046219ddd216a023f792356ddf127fcf372a72ec9b4cdac989ae5b0a455" moved to "@hashed/8c/1f/8c1f1046219ddd216a023f792356ddf127fcf372a72ec9b4cdac989ae5b0a455+99+deleted" for repository "project1/project1-build-images" gitlab.1.9waaf52jzavk@nreesv19 | 2022-01-24T12:37:30.122Z: Repository "project1/project1-build-images" was removed gitlab.1.9waaf52jzavk@nreesv19 | 2022-01-24T12:37:30.163Z: Deletion failed on project1/project1-build-images with the following message: no repository for such path
Error 500 when accessing this deleted project which is still listed
==> /var/log/gitlab/gitlab-rails/production_json.log <== gitlab.1.9waaf52jzavk@nreesv19 | { "method": "GET", "path": "/project1/project1", "format": "html", "controller": "ProjectsController", "action": "show", "status": 500, "time": "2022-01-24T12:32:53.578Z", "params": [ { "key": "namespace_id", "value": "project1" }, { "key": "id", "value": "project1" } ], "correlation_id": "01FT616APSFN0Q8S564JACQ387", "meta.user": "user1", "meta.project": "project1/project1", "meta.root_namespace": "project1", "meta.caller_id": "ProjectsController#show", "meta.remote_ip": "W.X.Y.Z", "meta.feature_category": "projects", "meta.client_id": "user/2", "remote_ip": "W.X.Y.Z", "user_id": 2, "username": "user1", "ua": "Mozilla/5.0 (...) Gecko/... Firefox/...", "queue_duration_s": 0.007804, "request_urgency": "default", "target_duration_s": 1, "gitaly_calls": 1, "gitaly_duration_s": 0.004056, "redis_calls": 18, "redis_duration_s": 0.002163, "redis_read_bytes": 1972, "redis_write_bytes": 1940, "redis_cache_calls": 16, "redis_cache_duration_s": 0.001861, "redis_cache_read_bytes": 1789, "redis_cache_write_bytes": 739, "redis_shared_state_calls": 1, "redis_shared_state_duration_s": 0.000105, "redis_shared_state_write_bytes": 53, "redis_sessions_calls": 1, "redis_sessions_duration_s": 0.000197, "redis_sessions_read_bytes": 183, "redis_sessions_write_bytes": 1148, "db_count": 37, "db_write_count": 0, "db_cached_count": 9, "db_replica_count": 0, "db_primary_count": 37, "db_replica_cached_count": 0, "db_primary_cached_count": 9, "db_replica_wal_count": 0, "db_primary_wal_count": 0, "db_replica_wal_cached_count": 0, "db_primary_wal_cached_count": 0, "db_replica_duration_s": 0.0, "db_primary_duration_s": 0.013, "cpu_s": 0.098098, "mem_objects": 50827, "mem_bytes": 4419576, "mem_mallocs": 9534, "mem_total_bytes": 6452656, "pid": 6160, "exception.class": "ActionView::Template::Error", "exception.message": "No route matches {:action=>"show", :controller=>"projects/tree", :id=>nil, :namespace_id=>#<Group id:45 @project1>, :project_id=>#<Project id:96 project1/project1>>}, possible unmatched constraints: [:id]\nDid you mean? namespace_project_tree_url", "exception.backtrace": [ "app/helpers/routing/projects_helper.rb:6:in
project_tree_path'", "app/presenters/project_presenter.rb:185:in
files_anchor_data'", "app/presenters/project_presenter.rb:32:instatistics_anchors'", "app/views/projects/_home_panel.html.haml:51", "app/views/projects/_home_panel.html.haml:46", "app/views/projects/show.html.haml:13", "app/controllers/application_controller.rb:133:in
render'", "app/controllers/application_controller.rb:541:inblock in allow_gitaly_ref_name_caching'", "lib/gitlab/gitaly_client.rb:322:in
allow_ref_name_caching'", "app/controllers/application_controller.rb:540:inallow_gitaly_ref_name_caching'", "ee/lib/gitlab/ip_address_state.rb:10:in
with'", "ee/app/controllers/ee/application_controller.rb:44:inset_current_ip_address'", "app/controllers/application_controller.rb:490:in
set_current_admin'", "lib/gitlab/session.rb:11:inwith_session'", "app/controllers/application_controller.rb:481:in
set_session_storage'", "lib/gitlab/i18n.rb:105:inwith_locale'", "lib/gitlab/i18n.rb:111:in
with_user_locale'", "app/controllers/application_controller.rb:475:inset_locale'", "app/controllers/application_controller.rb:469:in
set_current_context'", "lib/gitlab/metrics/elasticsearch_rack_middleware.rb:16:incall'", "lib/gitlab/middleware/rails_queue_duration.rb:33:in
call'", "lib/gitlab/middleware/speedscope.rb:13:incall'", "lib/gitlab/request_profiler/middleware.rb:17:in
call'", "lib/gitlab/database/load_balancing/rack_middleware.rb:23:incall'", "lib/gitlab/metrics/rack_middleware.rb:16:in
block in call'", "lib/gitlab/metrics/web_transaction.rb:46:inrun'", "lib/gitlab/metrics/rack_middleware.rb:16:in
call'", "lib/gitlab/jira/middleware.rb:19:incall'", "lib/gitlab/middleware/go.rb:20:in
call'", "lib/gitlab/etag_caching/middleware.rb:21:incall'", "lib/gitlab/middleware/multipart.rb:173:in
call'", "lib/gitlab/middleware/read_only/controller.rb:50:incall'", "lib/gitlab/middleware/read_only.rb:18:in
call'", "lib/gitlab/middleware/same_site_cookies.rb:27:incall'", "lib/gitlab/middleware/handle_malformed_strings.rb:21:in
call'", "lib/gitlab/middleware/basic_health_check.rb:25:incall'", "lib/gitlab/middleware/handle_ip_spoof_attack_error.rb:25:in
call'", "lib/gitlab/middleware/request_context.rb:21:incall'", "config/initializers/fix_local_cache_middleware.rb:11:in
call'", "lib/gitlab/middleware/compressed_json.rb:26:incall'", "lib/gitlab/middleware/rack_multipart_tempfile_factory.rb:19:in
call'", "lib/gitlab/middleware/sidekiq_web_static.rb:20:incall'", "lib/gitlab/metrics/requests_rack_middleware.rb:75:in
call'", "lib/gitlab/middleware/release_env.rb:13:in `call'" ], "db_duration_s": 0.00912, "view_duration_s": 0.0, "duration_s": 0.08828 }
Details of package version
Provide the package version installation details
GitLab Image 14.6.0.ee.0
Environment details
- Operating System: GitLab Image 14.6.0.ee.0
- Installation Target, remove incorrect values:
- Other: Docker 20.10.7
- Installation Type, remove incorrect values:
- Other: Docker
- Is there any other software running on the machine: not relevant
- Is this a single or multiple node installation? Single
- Resources
- CPU: 8 Cores Intel Xeon Gold
- Memory total: 16 GB