404 on "View File" in Diff view if file was also moved #803

Closed
opened 2025-11-02 03:37:18 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @ghost on GitHub (Jun 12, 2017).

Description

In a test repository I have uploaded to try.gitea.io, I look at a certain commit diff:
cbf49a36bc

The fifth file shown has not only been changed, but also been moved from hlp/listpusher.go to lob/listpusher.go in this commit. When I click on the "View File" button in the header bar of the file (marked in screenshot 1), I get a 404 error (screenshot 2). (The URL of the button link still refers to hlp/listpusher.go .)

The same happens with a Firefox browser without being logged in to try.gitea.org.

Screenshots

404_view_file_screenshot_1
404_view_file_screenshot_2

Originally created by @ghost on GitHub (Jun 12, 2017). - Gitea version (or commit ref): ad70af1 (the one currently on https://try.gitea.io/ [2017-06-12]) - Git version: whatever try.gitea.io currently uses; same for database - Operating system: my web client: current Debian Linux Jessie, current Chrome Browser, likely irrelevant - Can you reproduce the bug at https://try.gitea.io: - [x] Yes (provide example URL): https://try.gitea.io/jyrgenn/lingo/commit/cbf49a36bc353967f58b22de3d1b6ba5d04df7c0 https://try.gitea.io/jyrgenn/lingo/src/cbf49a36bc353967f58b22de3d1b6ba5d04df7c0/hlp/listpusher.go ## Description In a test repository I have uploaded to try.gitea.io, I look at a certain commit diff: https://try.gitea.io/jyrgenn/lingo/commit/cbf49a36bc353967f58b22de3d1b6ba5d04df7c0 The fifth file shown has not only been changed, but also been moved from `hlp/listpusher.go` to `lob/listpusher.go` in this commit. When I click on the "View File" button in the header bar of the file (marked in screenshot 1), I get a 404 error (screenshot 2). (The URL of the button link still refers to hlp/listpusher.go .) The same happens with a Firefox browser without being logged in to try.gitea.org. ## Screenshots ![404_view_file_screenshot_1](https://user-images.githubusercontent.com/11918910/27035714-a3546ac4-4f82-11e7-8f9d-84e499239435.png) ![404_view_file_screenshot_2](https://user-images.githubusercontent.com/11918910/27035715-a357dcf4-4f82-11e7-973d-dee88e2c23f8.png)
GiteaMirror added the type/bug label 2025-11-02 03:37:18 -06:00
Author
Owner

@ghost commented on GitHub (Jun 12, 2017):

Confirmed the behaviour with a new installation of Gitea 1.1.2 on Debian Linux Jessie (current) with Sqlite db and git 2.1.4, same web client.

@ghost commented on GitHub (Jun 12, 2017): Confirmed the behaviour with a new installation of Gitea 1.1.2 on Debian Linux Jessie (current) with Sqlite db and git 2.1.4, same web client.
Author
Owner

@ghost commented on GitHub (Jun 14, 2017):

Can confirm fix on try.gitea.io. Thanks!

@ghost commented on GitHub (Jun 14, 2017): Can confirm fix on try.gitea.io. Thanks!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#803