From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.2 required=3.0 tests=AWL,BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI shortcircuit=no autolearn=ham autolearn_force=no version=3.4.0 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 4B6D11F404 for ; Sat, 14 Apr 2018 13:11:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751054AbeDNNLe (ORCPT ); Sat, 14 Apr 2018 09:11:34 -0400 Received: from mout.gmx.net ([212.227.17.22]:49581 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750914AbeDNNLd (ORCPT ); Sat, 14 Apr 2018 09:11:33 -0400 Received: from [192.168.0.129] ([37.201.203.18]) by mail.gmx.com (mrgmx102 [212.227.17.168]) with ESMTPSA (Nemesis) id 0MMYZG-1f6ksJ1BfC-008N6f; Sat, 14 Apr 2018 15:11:29 +0200 Date: Sat, 14 Apr 2018 15:11:28 +0200 (DST) From: Johannes Schindelin X-X-Sender: virtualbox@MININT-6BKU6QN.europe.corp.microsoft.com To: phillip.wood@dunelm.org.uk cc: Johannes Sixt , Git Mailing List Subject: Re: Bug: rebase -i creates committer time inversions on 'reword' In-Reply-To: Message-ID: References: <5f5d5b88-b3ac-ed4f-ee24-6ce2cba2bd55@kdbg.org> User-Agent: Alpine 2.21.1 (DEB 209 2017-03-23) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Provags-ID: V03:K1:MUIV/Neo8PEu4q0NxGyA1/nnpX+gZFJcRbg9SlpO7McSR9Zs/kt c7KriHJcLGX8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KmbLWc= Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Hi, On Sat, 14 Apr 2018, Phillip Wood wrote: > On 13/04/18 17:52, Johannes Sixt wrote: > > > > I just noticed that all commits in a 70-commit branch have the same > > committer timestamp. This is very unusual on Windows, where rebase -i of > > such a long branch takes more than one second (but not more than 3 or > > so thanks to the builtin nature of the command!). > > > > And, in fact, if you mark some commits with 'reword' to delay the quick > > processing of the patches, then the reworded commits have later time > > stamps, but subsequent not reworded commits receive the earlier time > > stamp. This is clearly not intended. > > Oh dear, I think this is probably due to my series making rebase commit > in-process when the commit message isn't being edited. I didn't realize > that git cached the commit date rather than using the current time when > calling commit_tree_extended(). I'll take a look at it next week. Thanks. However, a quick lock at `git log @{u}.. --format=%ct` in my `sequencer-shears` branch thicket (which I rebase frequently on top of upstream's `master` using the last known-good `rebase-merges` sub-branch) shows that the commits have different-enough commit timestamps. (It is satisfying to see that multiple commits were made during the same second, of course.) So while I cannot find anything in the code that disagrees with Hannes' assessment, it looks on the surface as if I did not encounter the bug here. Curious. FWIW I agree with Hannes' patch. > I think 'git am' probably gives all patches the same commit time as well > if the commit date is cached though it wont suffer from the time-travel > problem. I thought that `git am` was the subject of such a complaint recently, but I thought that had been resolved? Apparently I misremember... Ciao, Dscho