GNOME Bugzilla – Bug 619211
gitg displays commit history incorrectly
Last modified: 2018-05-22 13:03:54 UTC
Created attachment 161571 [details] Before and after screenshots In the attached image A, we see the correctly-displayed commit history of my project. The highlighted commit is of interest. It has subject "Fix editing links" and SHA 4ff4e. Its parent commit is "Whitespace", SHA f562f2. I then moved a branch head, "filters", to refer to the "Whitespace" commit. I did not make any other changes to the repository. The result is displayed by gitg as in attached image B. The topology should be the same, a single line, with the "filters" ref attached to it. Instead, gitg has decided that there are now two completely separate lines of development. The highlighted commit, "Fix editing links", is the same in this picture, and its SHA and its parent's SHAs are the same. But gitg displays the parent commit incorrectly. Instead of displaying that the parent commit is "whitespace", as before, gitg's ancestry graph contains an infinite brown line that descends into the distant path and terminates below the repository's initial commit. gitk and git log --graph display the ancestry graph correctly.
Created attachment 161574 [details] Screenshot with correctly-drawn topology
Created attachment 161575 [details] Screenshot showing incorrectly-drawn topology
git-gui also displays the topology correctly.
Try enabling 'Show history in topological order' in the preferences. Does that fix the issue?
I do not see a 'Show history in topological order' in the preferences. I am using gitg 0.0.5. I will upgrade to 0.1.0 and see if the problem continues to appear.
The problem is fixed in 0.0.7, but only if I enable 'Show history in topological order'.
Created attachment 188689 [details] Complete repository that demonstrates the problem, plus screenshots This is a complete repository that demonstrates the graph rendering problem in gitg 0.0.7. The repository contains four commits, in a straight line, with no branches or merges: ddbdd9a (master) commit number 4 8551e09 commit number 3 97931de (HEAD, second) commit number 2 c402e0f (first) commit number 1 Screenshot-bad.png is a screenshot of gitg's rendering of the repository history. It is clearly broken. When I turn on "show history in topological order" in the Preferences dialog, the display is correct. Screenshot-good.png demonstrates this. But gitg should render this simple topology correctly, regardless of the preferences.
Recently, there were a few commits related to the graph rendering. I am not aware what changes those commits brought in. CC-ing nacho for details.
I came here to report this very problem and it looks like it has been sitting here for quite some time waiting for feedback. So I'll only add that I've been experiencing it since v0.2.x and it still happens quite frequently for me on 3.14.1 running on Arch Linux. It's not just a rare edge case. It does not happen with 'show history in topological order' checked in preferences but this mode is unusable to me because I have many long-lived branches. It puts the oldest branches at the top so that I have to scroll a long way to get to master or the most recent ones.
That shouldn't happen. Can you show an example, or have an example repo somewhere that shows the issue with topological order?
You mean the issue with the oldest branches being presented at the top? Or the problem described in this ticket? If the former then look at the screenshots called gitg-django-repo-non-topological.png and gitg-django-repo-topological.png (I'll attach them after posting this response). The first one shows master at the top while the second starts with ones dating back to 2005. It's this repo: https://github.com/django/django If you mean the latter, I can't post screenshots from the project I'm currently working at (it's not open source) but the repo called 'bat' already attached at the top of this ticket is a good example (see git-bat-repo-non-topological.png and git-bat-repo-topological.png).
Created attachment 299722 [details] gitg presenting branches in Django repo correctly when not in topological order
Created attachment 299723 [details] gitg presenting oldes branches in Django repo first when in topological order
Created attachment 299724 [details] gitg showing a single branch as multiple lines (incorrectly) in the 'bat' repo when not in topological order
Created attachment 299725 [details] gitg showing a single branch in the 'bat' repo correctly when in topological order
*** Bug 780401 has been marked as a duplicate of this bug. ***
*** Bug 777969 has been marked as a duplicate of this bug. ***
Hi, I too seem to experience a related problem with gitg 3.26.0: the history gets truncated when "Show history in topological order" is off. Here is the repository which shows the problem: https://git.ao2.it/gst-aseq-appsrc.git/ git log and gitweb show all the commits, but gitg doesn't. Hopefully the repository is small enough to make it easier to debug and solve the issue. IIRC in my case the problem started after a rebase and a "git stash drop". Thanks, Antonio
The issue I am seeing looks more like the one reported in https://bugzilla.gnome.org/show_bug.cgi?id=788090 so I will post further info over there, sorry for the noise.
How can I unsubscribe from this bug? I've logged in at bugzilla.gnome.org and I don't see any control for unsubscribing. I am not on the cc list, because I am the original reporter. I no longer care about updates to this bug which I reported in May of 2010, and I regret that I submitted the report at all.
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gitg/issues/8.