Defect #22864

Associated revisions mix timestamps of git committer and git author.

Added by Deniz Bahadir over 1 year ago. Updated over 1 year ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:SCM
Target version:-
Resolution:Duplicate Affected version:3.2.0

Description

Background information:

Git-commits have an author, who originally created the commit, and a committer who (finally) committed this commit to the Git-repository. Both come with their own timestamps.

  • In general, author and committer are the same.
  • They can be the same but have different dates associated with them
  • But they can even be different.

The problem

The problem is, that if these commits are displayed as associated revisions from a Redmine-ticket the author will be displayed with commit-date instead of the original author-date.

Suggested solution.

The best solution would probably be to always display both, author and committer with their respective dates.


Related issues

Duplicates Redmine - Defect #11710: Git: Repository view author/date inconsistency New

History

#1 Updated by Deniz Bahadir over 1 year ago

Example (Part 1)

The command git log --pretty=fuller displays the Git log with both, author and committer.

$ git log --pretty=fuller

commit 9031f50a6dce130fce991a28940e8c80574b8ff1
Author:     Developer1 <developer1 at me dot com>
AuthorDate: Fri May 20 15:18:06 2016 +0200
Commit:     Developer1 <developer1 at me dot com>
CommitDate: Fri May 20 15:18:06 2016 +0200

    Changes, which were just committed a single time by Developer1.

commit a46cac0249a0cfb3dc018148e7ce62d55760d565
Author:     Developer1 <developer1 at me dot com>
AuthorDate: Fri May 18 12:10:36 2016 +0200
Commit:     Developer1 <developer1 at me dot com>
CommitDate: Fri May 20 15:16:06 2016 +0200

    Changes, which where first committed by Developer1 and afterwards changed and recommitted
    (using "git commit --amend") by Developer1 and thereby modifying the first commit.

commit adeecde1f380ac64a4b1e9828cc114aa08e3a6a1
Author:     Developer2 <developer2 at me dot com>
AuthorDate: Mon Apr 25 11:19:42 2016 +0200
Commit:     Developer1 <developer1 at me dot com>
CommitDate: Thu May 16 16:08:37 2016 +0200

    Changes, which where originally (locally) committed and afterwards extracted as patch
    (using "git format-patch") by Developer2 and then applied to the current Git repository
    (using "git am") by Developer1.

In general, author and committer are the same, as displayed for the newest commit (9031f50a).
They can be the same but have different dates associated with them, as displayed in the middle commit (a46cac02).
But they can even be different, as displayed in the oldest commit (adeecde1).

#2 Updated by Deniz Bahadir over 1 year ago

Example (Part 2)

Addressing the commits from "Example (Part 1) from above, this is no problem for the newest commit (9031f50a), as author and committer are the same as are their associated dates.

Revision 9031f50a
Added by Developer1 42 minutes ago

Changes, which were just committed a single time by Developer1.

For the middle commit (a46cac02) this is wrong but could be interpreted as the committer and its commit-date.

Revision a46cac02
Added by Developer1 44 minutes ago

Changes, which where first committed by Developer1 and afterwards changed and recommitted
(using "git commit --amend") by Developer1 and thereby modifying the first commit.

But for the oldest commit (adeecde1) this is totally wrong, as it displays the author with the commit-date.

Revision adeecde1
Added by Developer2 4 days ago

Changes, which where originally (locally) committed and afterwards extracted as patch
(using "git format-patch") by Developer2 and then applied to the current Git repository
(using "git am") by Developer1.

#3 Updated by Toshi MARUYAMA over 1 year ago

  • Status changed from New to Closed
  • Resolution set to Duplicate

Duplicate of #11710.

#4 Updated by Toshi MARUYAMA over 1 year ago

  • Duplicates Defect #11710: Git: Repository view author/date inconsistency added

Also available in: Atom PDF