Skip to content

"Commits behind main" counter is not working reliable in branch overview #31599

Closed
@urz-hgw

Description

@urz-hgw

Description

Hi,

the number of "commits behind main" is not updated regularly for some reason in the branch overview page.

My steps to reproduce are:

  • Create a new repository
  • Add a testfile and commit
  • Create a new branch "dev" from "main"
  • Modify the testfile and commit to "main"
  • The branch overview shows either: "1|0" or "0|0"
  • Modify the testfile a second time and commit to "main"
  • Modify the testfile a third time and commit to "main"
  • The branch overview still shows "0|0" or "1|0"
    (see screenshot, it's taken from the Gitea demo site)

The CLI shows

git rev-list --left-right --count origin/main...origin/dev
3	0

When I now add a testfile to the "dev" branch and commit it, the branch overview updates correctly to "3|1".

In general, when doing commits on the "dev" branch, the correct number of "commits ahead of main" is shown immediately after each commit.

You can find my testrepo on the Gitea demo site here, I added some more commit on the "main" branch, the number should now be "5|1" but still shows "3|1".

Best regards
Daniel

Screenshots

Bildschirmfoto vom 2024-07-09 14-23-04

Gitea Version

1.22.1

Can you reproduce the bug on the Gitea demo site?

Yes

Operating System

Linux

Browser Version

Firefox 127.0.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions