<< Back to previous view |
[QB-1139] Git plugin. SCM changes detection is based on author date but not on commit date
|
|
Status: | Closed |
Project: | QuickBuild |
Component/s: | None |
Affects Version/s: | 3.1.62 |
Fix Version/s: | None |
Type: | Bug | Priority: | Minor |
Reporter: | Alexey Shumkin | Assigned To: | Steve Luo |
Resolution: | Won't Fix | Votes: | 0 |
Remaining Estimate: | Unknown | Time Spent: | Unknown |
Original Estimate: | Unknown | ||
Environment: |
Operating System Linux 2.6.33.7-co-0.7.9, i386
JVM OpenJDK Client VM 1.6.0_20, Sun Microsystems Inc. QuickBuild Version 3.1.62 - Thu Sep 29 09:39:59 MSK 2011 Git Support 3.1.11 |
Description |
Here is a citate from a QB log :
... 10:52:14,381 [master>checkout repo>checkout Git@drcis:8811] DEBUG - Executing command: git log -1 --date=raw --pretty=format:%ad 12cc11cf4c295a15f1c2ae97ad01c8a2ba52fb92 ... 10:52:14,459 [master>checkout repo>checkout Git@drcis:8811] DEBUG - 1321551015 +0400 10:52:14,459 [master>checkout repo>checkout Git@drcis:8811] DEBUG - Executing command: git log -1 --date=raw --pretty=format:%ad c78a27eb6dc5573d012f4f039b1553348bf0af6f ... 10:52:14,537 [master>checkout repo>checkout Git@drcis:8811] DEBUG - 1320684763 +0400 10:52:14,537 [master>checkout repo>checkout Git@drcis:8811] WARN - Ignoring fetching changes because the start revision (12cc11cf4c295a15f1c2ae97ad01c8a2ba52fb92) seems elder than end revision (c78a27eb6dc5573d012f4f039b1553348bf0af6f). ... As I suppose git plugin assumes linear development history (i.e. any later commit has a later date than a previous one). But commit in Git has two dates: author date and commit date (one per person responsible for a commit: "author" and "committer"). And the power of Git allows to reorder commits, rebasing, cherry-picking, etc. So, every commit can have two different dates: author date and commit date. Generally, they are not used to the same. During rebasing, cherry-picking and committing with -c/-C option commit can have author date set some time earlier then the committing moment (commit date). So, author date is not too reliable source to determine age of the commit relatively of previuos one. Commit date is more reliable, I guess. I guess git log -1 --date=raw --pretty=format:%cd must be used instead of git log -1 --date=raw --pretty=format:%ad The same is for changset log window (the date of changeset is an author date there, too) |
Comments |
Comment by Steve Luo [ 02/Feb/12 10:04 AM ] |
When user schema is one of below types:
Author Name, Auther Email, Author Name, Author Name and Email author date will be used, otherwise, commit date will be used. |