Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:107259 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 99854 invoked from network); 20 Sep 2019 11:45:13 -0000 Received: from unknown (HELO php-smtp3.php.net) (208.43.231.12) by pb1.pair.com with SMTP; 20 Sep 2019 11:45:13 -0000 Received: from php-smtp3.php.net (localhost [127.0.0.1]) by php-smtp3.php.net (Postfix) with ESMTP id D32A52D20C4 for ; Fri, 20 Sep 2019 02:23:04 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp3.php.net X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,FREEMAIL_REPLY,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS3215 2.6.0.0/16 X-Spam-Virus: No Received: from mail-io1-xd2e.google.com (mail-io1-xd2e.google.com [IPv6:2607:f8b0:4864:20::d2e]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by php-smtp3.php.net (Postfix) with ESMTPS for ; Fri, 20 Sep 2019 02:23:04 -0700 (PDT) Received: by mail-io1-xd2e.google.com with SMTP id b136so14637177iof.3 for ; Fri, 20 Sep 2019 02:23:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=GnnEe4RPpwN0pdltpYnLin3pZa4NepsdYRpNhOYh6eE=; b=FXtVBgsbgVsEfo8Lh06A/Fa16WD2/Xp3xlM9ps4laemxLscDI/2ZgeJ5rJJj4KC9eD Q6asFB+6KFc3PYE6tfiTvsjH7/PaHftuCZ+SXYL2s3y5GHgGctWb/6JwWMSWzRJ8OB/p qqv0RDs9+5IVU88g8wFhSRE6YZzSzOViDEo/qSI9BCZln8rK+y7XkyDhuzn0zCWTBcpX 0oKVGMi1KQ67sq1DNyNq4DS8praU+nmNdL+YOYgWV8J0jhOz0DSbuqBPh/ffgR2NROoJ OSdPcspFJuk31a5THYt3huM8nbN6Mp6NNyNcVKJYmtG0agti8JXWesaggFuAcTlQZtAh g0zQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=GnnEe4RPpwN0pdltpYnLin3pZa4NepsdYRpNhOYh6eE=; b=p9Kmd/85OWRIaQN1ZnNv7emjh5CPTTAeTu0MKy1rVxUymN1XfWerFDQCWNqDi2bw9A reKz2+EywdjS86jgnRml1JOYC0hqbYaA0NYMqmi9WLGyHdotKmfzErVMiGGQTa+XO2Ak CtiY5krrV4ZmCflaL/0Q2YP12QdtdK1iIrlYCAOJhTDuGle4BMnyQew4C5RWp/bsdZ/J eCU3bNZZMicj9CjtDPNmz6o7/y+Lz3GU+oglsGjVNwIiImVi1yogcgCRpMxJIIhrerMz K5vC7ljPCKLma7eaVivTMKheF5LW+ZDUH2nHqo4E0eq/UNoRtP/Oxinaek6E8bri9pSG jTwA== X-Gm-Message-State: APjAAAWHRfa+lXHIn8EfXHzjaGzqq83Tcx9Zr9J1v9nfIS9Kpn/Qh2FA Z3toeZNs9i86/iW7vRSzV3eJNmcI8j4aq7TnM28= X-Google-Smtp-Source: APXvYqx/IjPYjhrQFgaZBxZOYAk8/To5odpp8kauCKuNsM2l9Lqix1tQ84fh33xEDpUrryr0fi8cxVYAflEeeLb+r4k= X-Received: by 2002:a05:6638:1f2:: with SMTP id t18mr18185083jaq.67.1568971383489; Fri, 20 Sep 2019 02:23:03 -0700 (PDT) MIME-Version: 1.0 References: <44818c1e-07e4-19d5-2ef5-144ccb2b5c05@gmx.de> In-Reply-To: Date: Fri, 20 Sep 2019 12:22:36 +0300 Message-ID: To: Nikita Popov Cc: "guilhermeblanco@gmail.com" , "Christoph M. Becker" , PHP internals Content-Type: multipart/alternative; boundary="000000000000f9ca610592f89d1e" X-Envelope-From: Subject: Re: [PHP-DEV] Re: Question about merged PR #937 From: drealecs@gmail.com (=?UTF-8?Q?Alexandru_P=C4=83tr=C4=83nescu?=) --000000000000f9ca610592f89d1e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable I was quick to write an answer and forgot to search for a more detailed explanation online, being busy with some other work tasks. Github explains it here: https://help.github.com/en/articles/about-merge-methods-on-github Before enabling squashing commits, consider these disadvantages: > > - You lose information about when specific changes were originally > made and who authored the squashed commits. > > Alex On Fri, Sep 20, 2019 at 11:56 AM Alexandru P=C4=83tr=C4=83nescu wrote: > Hi Nikita, > > Yes, you are right that the author (and not the committer) is the one > taken in considerations for git blame and contributor display. Committer = is > just technical and related to who created/recreated a commit. > > But, unfortunately, you are wrong in believing that the author is > preserved during merging with squash. A squash merge is similar with a > normal commit, it has a single parent and it does not relate with the > original commits in the git's commit graph. > I can help with us making a quick test to demonstrate this. > > Alex > > On Fri, Sep 20, 2019 at 10:36 AM Nikita Popov > wrote: > >> On Fri, Sep 20, 2019 at 12:50 AM Alexandru P=C4=83tr=C4=83nescu >> wrote: >> >>> Hi Guilherme, >>> >>> That is what is happening when squashing commits during merge. >>> >>> I noticed this also few months ago but didn't mentioned it as I though >>> this >>> is one of the usual flows. >>> I quickly searched it now and found it here: >>> https://wiki.php.net/vcs/gitworkflow: "Additionally, the history of pul= l >>> requests often requires cleanup. For most pull requests, all commits ca= n >>> be >>> squashed into one." >>> >>> It could be considered a good practice to not pollute git history with = a >>> lot of small commits as it would hinder analyzing it later. >>> On the other hand I quite like (and promote) doing small incremental >>> steps >>> during a PR for multiple reasons that I can highlight if needed. >>> >>> Analyzing git history could be simplified by using --first-parent when >>> one >>> would not want to go in details on second parent of a merge commit with >>> individual detailed commits. >>> Also, there is no noticeable git performance improvements when using >>> squash. >>> >>> One of the advantages here would be that author would see his name in >>> contributors of a file or on repository level and be proud of it. >>> This is an important factor especially in open source software as >>> otherwise >>> it could leave a bitter taste that you are not fully recognized as >>> contributor in git's history and might decrease the chance to future >>> contributions. >>> >>> Would it be up for discussion to define the way to merge pull requests = in >>> order to avoid squashing merges by a different author? Has this issue >>> been >>> discussed before? >>> The mention that "the history of pull requests often requires cleanup" = is >>> not clearly defined. I would not agree that PR-937 >>> https://github.com/php/php-src/pull/937/commits or PR-911 >>> https://github.com/php/php-src/pull/911/commits required squashing. >>> As a simple solution, if squashing is required it should be done by the >>> original author, before merging. >>> >>> Regards, >>> Alex >>> >> >> Git has separate notions of "author" and "committer". The author is >> preserved during squashing, and the author is what is relevant for >> contribution statistics on GitHub. If the author is preserved but the us= er >> doesn't show up as a contributor, that's likely due to a missing mail >> mapping between the email address and the GitHub account. >> >> Nikita >> >> >>> On Thu, Sep 19, 2019 at 8:20 PM guilhermeblanco@gmail.com < >>> guilhermeblanco@gmail.com> wrote: >>> >>> > Thanks for the clarification Christoph! >>> > Somehow I couldn't see it when looking for the commit hash. Sorry for >>> > the disturbance in the list here. >>> > >>> > PS: I find it funny that even though I'm the original author of the >>> > code, I don't show as a contributor in any statistics. >>> > It'd be a shame to not be considered as a valid voter for "lack of >>> > recent contribution" to the language. >>> > >>> > Cheers, >>> > >>> > >>> > On Thu, Sep 19, 2019 at 12:58 PM Christoph M. Becker < >>> cmbecker69@gmx.de> >>> > wrote: >>> > > >>> > > On 19.09.2019 at 17:01, guilhermeblanco@gmail.com wrote: >>> > > > One of my old PRs to PHP that was claimed to be merged disappeare= d >>> > > > from master. However, the upgrade note is still there in master a= nd >>> > > > 7.4beta1. >>> > > > >>> > > > Here is the PR: https://github.com/php/php-src/pull/937 >>> > > > Here is the commit referencing it: >>> > > > >>> > >>> https://github.com/php/php-src/commit/0adfa03397edcde8cba3bae2032b1f2ef= 26ea760 >>> > > > >>> > > > Please let me know if there's anything I can do to help. >>> > > >>> > > From what I can tell, everything is there. PR #911 has been merged >>> as >>> > > < >>> > >>> http://git.php.net/?p=3Dphp-src.git;a=3Dcommit;h=3D094d409b3d34c51f49e0= 121e5ccfe8b2a717aaf6 >>> > >, >>> > > and parts of that PR already with PR #928 as >>> > > < >>> > >>> http://git.php.net/?p=3Dphp-src.git;a=3Dcommit;h=3Df48c2327403ce76a870e= 74f31a069a64dfb711a2 >>> > >. >>> > > >>> > > -- >>> > > Christoph M. Becker >>> > >>> > >>> > >>> > -- >>> > Guilherme Blanco >>> > SVP Technology at Statflo Inc. >>> > Mobile: +1 647 232 5599 >>> > >>> > -- >>> > PHP Internals - PHP Runtime Development Mailing List >>> > To unsubscribe, visit: http://www.php.net/unsub.php >>> > >>> > >>> >> --000000000000f9ca610592f89d1e--