Add single comment when reviewing code in deleted file generates fatal: no such path #2222

Closed
opened 2025-11-02 04:28:11 -06:00 by GiteaMirror · 4 comments
Owner

Originally created by @mkienenb on GitHub (Aug 20, 2018).

Gitea version (or commit ref):

/var/lib/gitea>sudo /usr/local/bin/gitea --version
Gitea version 1b2aff0 built with: bindata, sqlite
[master snapshot grabbed on Aug 15th]

  • Git version:
    git version 2.18.0

  • Operating system:
    CentOS release 6.4 (Final)

  • Database (use [x]):

    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:

    • Yes (provide example URL)
    • No
    • Not relevant
    • Very likely, but I couldn't turn up an example PR to comment on right away.
  • Log gist:

    2018/08/20 09:29:23 [.../repo/pull_review.go:77 CreateCodeComment()] [E] CreateCodeComment: LineBlame[refs/pull/1/head, /home/git/gitea-repositories/mlk/ebill.git, WEB-INF/lib/.gitignore, 1]: exit status 128 - fatal: no such path WEB-INF/lib/.gitignore in refs/pull/1/head

Description

Attempting to add a review comment to a deleted file generates an error and

  1. Create PR including deleted file
  2. Click "Files changed"
  3. Click "+" on any line of a deleted file.
  4. Enter any comment.
  5. Click "Add single comment"

Generates log entry above. Redirects to 500 Internal Server Error page.

Screenshots

See before and after here.

https://gist.github.com/mkienenb/016013ce9a50653ec02859d9fff14415

Originally created by @mkienenb on GitHub (Aug 20, 2018). Gitea version (or commit ref): /var/lib/gitea>sudo /usr/local/bin/gitea --version Gitea version 1b2aff0 built with: bindata, sqlite [master snapshot grabbed on Aug 15th] - Git version: git version 2.18.0 - Operating system: CentOS release 6.4 (Final) - Database (use `[x]`): - [ ] PostgreSQL - [ ] MySQL - [ ] MSSQL - [x] SQLite - Can you reproduce the bug at https://try.gitea.io: - [ ] Yes (provide example URL) - [ ] No - [ ] Not relevant - [x] Very likely, but I couldn't turn up an example PR to comment on right away. - Log gist: 2018/08/20 09:29:23 [.../repo/pull_review.go:77 CreateCodeComment()] [E] CreateCodeComment: LineBlame[refs/pull/1/head, /home/git/gitea-repositories/mlk/ebill.git, WEB-INF/lib/.gitignore, 1]: exit status 128 - fatal: no such path WEB-INF/lib/.gitignore in refs/pull/1/head ## Description Attempting to add a review comment to a deleted file generates an error and 1) Create PR including deleted file 2) Click "Files changed" 3) Click "+" on any line of a deleted file. 4) Enter any comment. 5) Click "Add single comment" Generates log entry above. Redirects to 500 Internal Server Error page. ## Screenshots <!-- **If this issue involves the Web Interface, please include a screenshot** --> See before and after here. https://gist.github.com/mkienenb/016013ce9a50653ec02859d9fff14415
GiteaMirror added the type/bug label 2025-11-02 04:28:11 -06:00
Author
Owner

@mkienenb commented on GitHub (Aug 20, 2018):

@lafriks Ping.

@mkienenb commented on GitHub (Aug 20, 2018): @lafriks Ping.
Author
Owner

@lafriks commented on GitHub (Aug 21, 2018):

Was PR created from fork on same repository other branch?

@lafriks commented on GitHub (Aug 21, 2018): Was PR created from fork on same repository other branch?
Author
Owner

@mkienenb commented on GitHub (Aug 21, 2018):

Was PR created from fork on same repository other branch?

It's hard to understand what you are asking.

User A owns the repo. User B is a collaborator (administrator) for the repo.
User B pushed some-branch to User A's repo and created a PR.

@mkienenb commented on GitHub (Aug 21, 2018): > Was PR created from fork on same repository other branch? It's hard to understand what you are asking. User A owns the repo. User B is a collaborator (administrator) for the repo. User B pushed some-branch to User A's repo and created a PR.
Author
Owner

@lafriks commented on GitHub (Sep 16, 2018):

PR #4682 fixes this issue

@lafriks commented on GitHub (Sep 16, 2018): PR #4682 fixes this issue
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#2222