You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@calcite.apache.org by Vladimir Sitnikov <si...@gmail.com> on 2021/12/02 17:45:49 UTC

Enable "squash and merge" button in GitHub UI

Hi,

I see "squash and merge" is not enabled in GitHub.
I am going to enable it soon, so we can merge PRs as single-commit changes,
and we no longer ask
contributors to "squash changes" manually.
I've no idea why the button was disabled.

See https://github.com/apache/calcite/pull/2629

Vladimir

Re: Enable "squash and merge" button in GitHub UI

Posted by Vladimir Sitnikov <si...@gmail.com>.
I wonder if that has already been fixed.

What do you think if I temporary enable the button, try it with
https://github.com/apache/calcite/pull/2628 and then either keep the button
or add a comment to asf.yaml?

Vladimir

Re: Enable "squash and merge" button in GitHub UI

Posted by Alessandro Solimando <al...@gmail.com>.
In Spark they have bots that understand commands like "test"/"retest", and
it helps IMO, in absence of a UI button.

So I think it would be great to have a "/squash" command à la IRC :)

Best regards,
Alessandro

On Mon, 6 Dec 2021 at 22:12, Vladimir Sitnikov <si...@gmail.com>
wrote:

> I wonder if we can add GitHub action that would react to committers comment
> /squash by squashing the commits and pushing --force-with-lease to the fork
> branch.
>
> If pushing to the fork is not possible in GHA, then something like /merge
> that squashes, rebases and pushes to apache/calcite would be good as well.
>
> That is slightly less convenient than a UI button, however, it would be way
> better than spending time on trivial squashes.
>
> I think that approach would keep the author/committer info, and it would be
> easily accessible
>
>
> Vladimir
>

Re: Enable "squash and merge" button in GitHub UI

Posted by Vladimir Sitnikov <si...@gmail.com>.
I wonder if we can add GitHub action that would react to committers comment
/squash by squashing the commits and pushing --force-with-lease to the fork
branch.

If pushing to the fork is not possible in GHA, then something like /merge
that squashes, rebases and pushes to apache/calcite would be good as well.

That is slightly less convenient than a UI button, however, it would be way
better than spending time on trivial squashes.

I think that approach would keep the author/committer info, and it would be
easily accessible


Vladimir

Re: Enable "squash and merge" button in GitHub UI

Posted by Julian Hyde <jh...@gmail.com>.
It definitely makes sense to track who commits what. We want to give credit to active committers!

To see the committer, I use ‘--format=fuller’, e.g.

  $ git --format=fuller origin/master

  commit 7c423ef23878271b1c50c03629ebfff674985681
  Author:     huzhe <il...@163.com>
  AuthorDate: Sun Nov 14 11:27:55 2021 +0800
  Commit:     NobiGo <no...@gmail.com>
  CommitDate: Mon Nov 22 15:08:48 2021 +0800

    [CALCITE-4876] Converting RelNode to SQL with CalciteSqlDialect gets wrong result while EnumerableIntersect is followed by EnumerableLimit

  commit 065e323da89ca73a46bec195efc7bd4019dc4f2f
  Author:     xwkuang5 <lo...@gmail.com>
  AuthorDate: Mon Nov 1 09:09:49 2021 -0400
  Commit:     Jacques Nadeau <ja...@apache.org>
  CommitDate: Thu Nov 18 09:41:02 2021 -0800

    [CALCITE-4841] Support decimal column type in CSV file format
    
    - Introduce a new `decimal` type in the CSV file format for
      more accurate representation of decimal data.
    - Implement the `decimal` SQL type using the BigDecimal JAVA type.

Julian



> On Dec 2, 2021, at 1:26 PM, Vladimir Sitnikov <si...@gmail.com> wrote:
> 
> We have many committers, and it might make sense to keep track of who
> commits what.
> 
> Squash and merge behaviour changed in 2020 :(
> 
> 
> https://github.community/t/authorship-of-merge-commits-made-by-github-apps-changed/2971/33
> 
> Vladimir


Re: Enable "squash and merge" button in GitHub UI

Posted by Vladimir Sitnikov <si...@gmail.com>.
We have many committers, and it might make sense to keep track of who
commits what.

Squash and merge behaviour changed in 2020 :(


https://github.community/t/authorship-of-merge-commits-made-by-github-apps-changed/2971/33

Vladimir

Re: Enable "squash and merge" button in GitHub UI

Posted by Jess Balint <jb...@gmail.com>.
Author is retained there. It's not set to the person who merged the PR.

On Thu, Dec 2, 2021 at 2:58 PM Vladimir Sitnikov <
sitnikov.vladimir@gmail.com> wrote:

> >I've never experienced this with other (non-Apache) projects.
>
> https://github.com/JetBrains/kotlin-wrappers/pull/969
>
> git show --format=full a3ff898f4f4e36d5a8bba9c1cbbefa924a9f5386
>
> =>
>
> commit a3ff898f4f4e36d5a8bba9c1cbbefa924a9f5386
> Author: Victor Turansky <victor... ail.com>
> Commit: GitHub <no...@github.com>
>
> :(
>
> Vladimir
>

Re: Enable "squash and merge" button in GitHub UI

Posted by Vladimir Sitnikov <si...@gmail.com>.
>I've never experienced this with other (non-Apache) projects.

https://github.com/JetBrains/kotlin-wrappers/pull/969

git show --format=full a3ff898f4f4e36d5a8bba9c1cbbefa924a9f5386

=>

commit a3ff898f4f4e36d5a8bba9c1cbbefa924a9f5386
Author: Victor Turansky <victor... ail.com>
Commit: GitHub <no...@github.com>

:(

Vladimir

Re: Enable "squash and merge" button in GitHub UI

Posted by Charles Givre <cg...@gmail.com>.
Hello all, 
We enabled the squash and merge feature in our github repo (Apache Drill) about a year ago.  Prior to that we were requiring all PR authors to squash all commits prior to merging.  It made our lives a bit easier as there were A LOT fewer mistakes when people would squash commits and accidentally include things they didn't mean to and things like that.  Of course, developers who didn't want to use that feature can still squash their commits the "old fashioned" way.  Overall, there was no downside and IMHO a lot of up side.
Best,
-- C



> On Dec 2, 2021, at 3:53 PM, Jess Balint <jb...@gmail.com> wrote:
> 
> Where/why is it lost? I've never experienced this with other (non-Apache)
> projects.
> 
> On Thu, Dec 2, 2021 at 2:32 PM Vladimir Sitnikov <
> sitnikov.vladimir@gmail.com> wrote:
> 
>> Thanks for the pointers. The committer info is lost indeed.
>> I would add the comments to asf.yaml so we can re-iterate later.
>> 
>> Vladimir
>> 


Re: Enable "squash and merge" button in GitHub UI

Posted by Jess Balint <jb...@gmail.com>.
Where/why is it lost? I've never experienced this with other (non-Apache)
projects.

On Thu, Dec 2, 2021 at 2:32 PM Vladimir Sitnikov <
sitnikov.vladimir@gmail.com> wrote:

> Thanks for the pointers. The committer info is lost indeed.
> I would add the comments to asf.yaml so we can re-iterate later.
>
> Vladimir
>

Re: Enable "squash and merge" button in GitHub UI

Posted by Vladimir Sitnikov <si...@gmail.com>.
Thanks for the pointers. The committer info is lost indeed.
I would add the comments to asf.yaml so we can re-iterate later.

Vladimir

Re: Enable "squash and merge" button in GitHub UI

Posted by Stamatis Zampetakis <za...@gmail.com>.
Here is the previous discussion:
https://lists.apache.org/thread/sjl40ts0mmkbpxbcvnyfzxcytvvsy82c

Best,
Stamatis

On Thu, Dec 2, 2021 at 7:21 PM Stamatis Zampetakis <za...@gmail.com>
wrote:

> There was a discussion on why it was disabled but can't find the link at
> the moment.
> I know that by using this button the committer information is lost
> (replaced by GitHub).
>
> Hive is making use of it and the commit logs looks like below:
>
> commit a8e50734e0460e506f1762fbe0f628bcb444b8f5
> Author:     Denys Kuzmenko <dk...@cloudera.com>
> AuthorDate: Tue Nov 30 10:09:06 2021 +0200
> Commit:     GitHub <no...@github.com>
> CommitDate: Tue Nov 30 09:09:06 2021 +0100
>
>     HIVE-25710: Config used to enable non-blocking TRUNCATE is not
> properly propagated (Denys Kuzmenko, reviewed by Karen Coppage and Peter
> Vary)
>
>     Closes #2796
>
>
> On Thu, Dec 2, 2021 at 6:46 PM Vladimir Sitnikov <
> sitnikov.vladimir@gmail.com> wrote:
>
>> Hi,
>>
>> I see "squash and merge" is not enabled in GitHub.
>> I am going to enable it soon, so we can merge PRs as single-commit
>> changes,
>> and we no longer ask
>> contributors to "squash changes" manually.
>> I've no idea why the button was disabled.
>>
>> See https://github.com/apache/calcite/pull/2629
>>
>> Vladimir
>>
>

Re: Enable "squash and merge" button in GitHub UI

Posted by Stamatis Zampetakis <za...@gmail.com>.
There was a discussion on why it was disabled but can't find the link at
the moment.
I know that by using this button the committer information is lost
(replaced by GitHub).

Hive is making use of it and the commit logs looks like below:

commit a8e50734e0460e506f1762fbe0f628bcb444b8f5
Author:     Denys Kuzmenko <dk...@cloudera.com>
AuthorDate: Tue Nov 30 10:09:06 2021 +0200
Commit:     GitHub <no...@github.com>
CommitDate: Tue Nov 30 09:09:06 2021 +0100

    HIVE-25710: Config used to enable non-blocking TRUNCATE is not properly
propagated (Denys Kuzmenko, reviewed by Karen Coppage and Peter Vary)

    Closes #2796


On Thu, Dec 2, 2021 at 6:46 PM Vladimir Sitnikov <
sitnikov.vladimir@gmail.com> wrote:

> Hi,
>
> I see "squash and merge" is not enabled in GitHub.
> I am going to enable it soon, so we can merge PRs as single-commit changes,
> and we no longer ask
> contributors to "squash changes" manually.
> I've no idea why the button was disabled.
>
> See https://github.com/apache/calcite/pull/2629
>
> Vladimir
>