GitHub protected branches

91 views
Skip to first unread message

Aaron Meurer

unread,
Sep 4, 2015, 12:00:04 PM9/4/15
to sy...@googlegroups.com

Harsh Gupta

unread,
Sep 4, 2015, 2:02:24 PM9/4/15
to sy...@googlegroups.com
Cool, I vote for protecting our master branch.

On 4 September 2015 at 21:29, Aaron Meurer <asme...@gmail.com> wrote:
> https://github.com/blog/2051-protected-branches-and-required-status-checks
>
> --
> You received this message because you are subscribed to the Google Groups "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
> To post to this group, send email to sy...@googlegroups.com.
> Visit this group at http://groups.google.com/group/sympy.
> To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/CAKgW%3D6%2BxB%2BNydQFPMEjCeGoJgMw1LS8f%3Dbsdg42hU3sBHepJZg%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.



--
Harsh

Sartaj Singh

unread,
Sep 4, 2015, 2:10:27 PM9/4/15
to sy...@googlegroups.com
> Cool, I vote for protecting our master branch.
+1


For more options, visit https://groups.google.com/d/optout.



--
Regards
Sartaj Singh

Mathematics and Computing,
Indian Institute of Technology,
Varanasi - 221 005 INDIA

Jason Moore

unread,
Sep 4, 2015, 3:02:18 PM9/4/15
to sy...@googlegroups.com
I'm pretty sure that most "new author" commits are force pushed to master and when they aren't, i.e. use a PR, there is high likelihood of merge conflicts when there are other new authors. If we protect master, we'll have to deal with this.

Aaron Meurer

unread,
Sep 4, 2015, 3:35:14 PM9/4/15
to sy...@googlegroups.com
They better not be.

They are often pushed directly to master, but that's different from
force pushing (i.e., pushing a non-fast forward commit). As far as I
can tell, this won't disable directly pushing without a pull request.

Aaron Meurer
> https://groups.google.com/d/msgid/sympy/CAP7f1AhgrJ2O6im8hHhaeopqYi%2BD7CoYhL%3DaeovZBrHZ%2B9_7Yg%40mail.gmail.com.

Jason Moore

unread,
Sep 4, 2015, 4:11:13 PM9/4/15
to sy...@googlegroups.com
Sorry, I'm probably misunderstanding what the protected branches are.

Aaron Meurer

unread,
Sep 23, 2015, 4:12:59 PM9/23/15
to sy...@googlegroups.com
I've enabled branch protection for master on sympy/sympy. I still
recommend removing write access to origin as described at
https://github.com/sympy/sympy/wiki/Pushing-patches as pushing to
master directly is still allowed (you just can't force push).

Aaron Meurer
> https://groups.google.com/d/msgid/sympy/CAP7f1AjuA9G7-NJhd_qE4yHPrYeja%3D8EeYfaHHU9ZxBWcB7EdQ%40mail.gmail.com.

Ondřej Čertík

unread,
Sep 23, 2015, 6:59:59 PM9/23/15
to sympy
On Wed, Sep 23, 2015 at 2:12 PM, Aaron Meurer <asme...@gmail.com> wrote:
> I've enabled branch protection for master on sympy/sympy. I still
> recommend removing write access to origin as described at
> https://github.com/sympy/sympy/wiki/Pushing-patches as pushing to
> master directly is still allowed (you just can't force push).

So the worst that can happen now is that somebody with push access
pushes some patches into master that we don't want. And the fix is
then just disabling the protection, resetting the master and
re-enabling the branch protection again. That's an improvement.

Even better would be if github disallows any pushes to master, but
even the current solution is not bad.

Thanks Aaron.

Ondrej

Aaron Meurer

unread,
Sep 23, 2015, 7:06:19 PM9/23/15
to sy...@googlegroups.com
You can do that too, but it is tied to Travis CI, so that you can't
merge anything to master unless the Travis tests pass.

Actually, it looks like you can choose which status checks are
required, so maybe not requiring any will amount to this. I'm going to
try this (https://github.com/sympy/sympy/settings/branches/master). If
you find you can't merge branches that you should be able to, please
let me know so I can revert it.

By the way, I also enabled branch protection for all the other SymPy
repos. Hopefully this won't break any of our bots that push to various
gh-pages branches.

Aaron Meurer

>
> Thanks Aaron.
>
> Ondrej
>
> --
> You received this message because you are subscribed to the Google Groups "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
> To post to this group, send email to sy...@googlegroups.com.
> Visit this group at http://groups.google.com/group/sympy.
> To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/CADDwiVBA6yDA1ko5oXchVyjrHYZ_6dgu5ByiyK7Gtsi-TPzJiw%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages