GetActivityStats: FillFromGit: Failed to get GetCodeActivityStats for repository #8500

Closed
opened 2025-11-02 08:08:59 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @somera on GitHub (Feb 5, 2022).

Gitea Version

1.16.0

Git Version

2.25.1

Operating System

Ubuntu 20.04.3

How are you running Gitea?

Precompiled gitea-1.16.0-linux-amd64

Database

PostgreSQL

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Description

In my Gitea mirror I get this error (http://nuc-mini-celeron:3000/gitea/gitea/activity)

image

==> gitea.log <==
2022/02/05 01:31:35 ...web/repo/activity.go:60:Activity() [E] GetActivityStats: FillFromGit: Failed to get GetCodeActivityStats for repository.
        Error: exit status 128
        Stderr: fatal: ambiguous argument 'master': unknown revision or path not in the working tree.
        Use '--' to separate paths from revisions, like this:
        'git <command> [<revision>...] -- [<file>...]'

        /source/routers/web/repo/activity.go:60 (0x1d1c503)
        /source/modules/web/route.go:74 (0x1cccbe4)
        /usr/local/go/src/net/http/server.go:2047 (0x77e98e)
        /go/pkg/mod/github.com/go-chi/chi/v5@v5.0.4/mux.go:442 (0x14e2c15)
        /usr/local/go/src/net/http/server.go:2047 (0x77e98e)
        /source/modules/web/route.go:113 (0x1ccd3c5)
        /usr/local/go/src/net/http/server.go:2047 (0x77e98e)
        /source/modules/web/route.go:113 (0x1ccd3c5)
        /usr/local/go/src/net/http/server.go:2047 (0x77e98e)
        /source/modules/web/route.go:113 (0x1ccd3c5)
        /usr/local/go/src/net/http/server.go:2047 (0x77e98e)

Screenshots

No response

Originally created by @somera on GitHub (Feb 5, 2022). ### Gitea Version 1.16.0 ### Git Version 2.25.1 ### Operating System Ubuntu 20.04.3 ### How are you running Gitea? Precompiled gitea-1.16.0-linux-amd64 ### Database PostgreSQL ### Can you reproduce the bug on the Gitea demo site? No ### Log Gist _No response_ ### Description In my Gitea mirror I get this error (http://nuc-mini-celeron:3000/gitea/gitea/activity) ![image](https://user-images.githubusercontent.com/8334250/152621019-a667edfd-5614-4bc2-9277-a14d779cb8ec.png) ``` ==> gitea.log <== 2022/02/05 01:31:35 ...web/repo/activity.go:60:Activity() [E] GetActivityStats: FillFromGit: Failed to get GetCodeActivityStats for repository. Error: exit status 128 Stderr: fatal: ambiguous argument 'master': unknown revision or path not in the working tree. Use '--' to separate paths from revisions, like this: 'git <command> [<revision>...] -- [<file>...]' /source/routers/web/repo/activity.go:60 (0x1d1c503) /source/modules/web/route.go:74 (0x1cccbe4) /usr/local/go/src/net/http/server.go:2047 (0x77e98e) /go/pkg/mod/github.com/go-chi/chi/v5@v5.0.4/mux.go:442 (0x14e2c15) /usr/local/go/src/net/http/server.go:2047 (0x77e98e) /source/modules/web/route.go:113 (0x1ccd3c5) /usr/local/go/src/net/http/server.go:2047 (0x77e98e) /source/modules/web/route.go:113 (0x1ccd3c5) /usr/local/go/src/net/http/server.go:2047 (0x77e98e) /source/modules/web/route.go:113 (0x1ccd3c5) /usr/local/go/src/net/http/server.go:2047 (0x77e98e) ``` ### Screenshots _No response_
GiteaMirror added the type/question label 2025-11-02 08:08:59 -06:00
Author
Owner

@zeripath commented on GitHub (Feb 6, 2022):

"master" will only be used if your repository says that it's default branch is "master".

The database entry for this repository's default branch is master therefore the code activity stats page is asking for the master branch.

You should update this repository's default branch on its settings page.

@zeripath commented on GitHub (Feb 6, 2022): "master" will only be used if your repository says that it's default branch is "master". The database entry for this repository's default branch is master therefore the code activity stats page is asking for the master branch. You should update this repository's default branch on its settings page.
Author
Owner

@somera commented on GitHub (Feb 6, 2022):

Thx. The change fixed the problem.

@somera commented on GitHub (Feb 6, 2022): Thx. The change fixed the problem.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#8500