Gitlab-ce 11.11.8 upgrade to 12.0.12 got some uploads file path 404 not found

:hugs: Please help fill in this template with all the details to help others help you more efficiently. Use formatting blocks for code, config, logs and ensure to remove sensitive data.

Problem to solve

Describe your question in as much detail as possible:

  • What are you seeing, and how does that differ from what you expect to see?
  • After upgrade gitlab-ce version from 11.11.8 to 12.0.12, some of the uploads file path got 404
  • Consider including screenshots, error messages, and/or other helpful visuals

Steps to reproduce

Which troubleshooting steps have you already taken? Can you link to any docs or other resources so we know where you have been?
With a fresh installation of gitlab-ce 11.11.8 and upgrade is no problem.
Even I tried backup and restore to a new server, then do the upgrade, problem still comes the same with some of the uploads file path 404, from the url, I see it lost the group/project path.

Configuration

Provide screenshots from the GitLab UI showing relevant configuration, if applicable.
On self-managed instances, add the relevant configuration settings or changes.
Just a default gitlab.rb file, without any specific configuration.

Versions

Please select whether options apply, and add the version information.

  • Self-managed

Versions

Helpful resources

  1. Before opening a new topic, make sure to search for keywords in the forum search
  2. Check the GitLab project for existing issues. If you encounter a bug, please create a bug report issue.
  3. Troubleshooting docs: Self-managed GitLab instances.

Thanks for taking the time to be thorough in your request, it really helps! :blush:

Update:
we tried upgrade to 12.0.6 and everything is working fine. But after this version, the problem comes out.
Upload file url:
Before upgrade:
https://ec2-18-167-173-176.ap-east-1.compute.amazonaws.com/wireless-tag/general-discussions/uploads/0be42b48c44380399fea22a00ca3ecd4/e554dcc2-5daa-4de8-baab-cb1333f90303.jpg

After upgrade:
https://ec2-18-167-173-176.ap-east-1.compute.amazonaws.com/uploads/0be42b48c44380399fea22a00ca3ecd4/e554dcc2-5daa-4de8-baab-cb1333f90303.jpg

Looks like the former group/project path is missing.

Attached the log below:

Started GET “/wireless-tag/general-discussions/noteable/issue/5349/notes” for 103.229.70.74 at 2024-08-13 10:43:51 +0800
Processing by Projects::NotesController#index as JSON
Parameters: {“namespace_id”=>“wireless-tag”, “project_id”=>“general-discussions”, “target_type”=>“issue”, “target_id”=>“5349”}
Completed 200 OK in 14ms (Views: 0.1ms | ActiveRecord: 2.7ms)
Started GET “/uploads/a940873abf6a6ccc974d30b3704995f6/%E4%BC%81%E4%B8%9A%E5%BE%AE%E4%BF%A1%E6%88%AA%E5%9B%BE_bf49d932-6b8c-495b-bdcb-82903f587c0e.png” for 103.229.70.74 at 2024-08-13 10:43:53 +0800
Processing by ApplicationController#route_not_found as PNG
Parameters: {“unmatched_route”=>“uploads/a940873abf6a6ccc974d30b3704995f6/企业微信截图_bf49d932-6b8c-495b-bdcb-82903f587c0e”}
Completed 404 Not Found in 7ms (ActiveRecord: 1.1ms)

Any possible we can correct the path?