github3.py
github3.py copied to clipboard
Add support for delete_branch_on_merge flag
Repos can be configured to delete branches when PRs are merged, as described here: https://help.github.com/en/github/administering-a-repository/managing-the-automatic-deletion-of-branches
The GitHub API now supports a delete_branch_on_merge
flag on the following endpoints:
- https://developer.github.com/v3/repos/#create
- https://developer.github.com/v3/repos/#edit
This PR adds support for that flag to everywhere that repos can be created or edited.
I wasn't sure how to re-record the cassettes for the integration tests that are now failing. Any assistance with this would be appreciated!
The cassettes are from betamax, and the docs here can get you started.
However the downside here is that it uses personal GitHub access tokens to record the interactions, and your account may not have the rights to do the things you need to re-record. You may have to create new test repos/issues/etc. if you run into that, or one of us will have to record it for you.
@omgjlk I looked at rerecording the cassettes so we can get this merged. It's a feature that would save me some clicks. Unfortunately it requires admin level privileges on the github3/urllib repo.
Alright, I'll set aside some time to get a cassette recorded for this. In the mean time can you fix up the merge conflict?
@omgjlk it's not my pull request. I can fork it and propose a new PR with the AUTHORS.txt fixed, but that doesn't feel fair to @nwalters512. If he doesn't reply soon I'll sort it.
Starting third-party-check jobs. Warning: Failed to update check run openstack/third-party-check: 403 Resource not accessible by integration
Just resolved the merge conflict! @omgjlk it sounds like I won't be able to record the cassette since it would require me to have admin privileges; it'd be much appreciated if you could do that on my behalf as you indicated.
Build failed (third-party-check pipeline) integration testing on OpenDev. For information on how to proceed, see https://docs.opendev.org/opendev/infra-manual/latest/developers.html#automated-testing
- tox-py35-on-zuul : FAILURE in 8m 47s
Warning: Failed to update check run openstack/third-party-check: 403 Resource not accessible by integration Failed to create check run openstack/third-party-check: 403 Resource not accessible by integration
@staticdev as mentioned previously in the thread, I'm unable to record the cassettes as I don't have admin permissions for the repos used in the tests. I wish I could help out here, but I really need a maintainer (or someone with the right permissions) to do that on my behalf.
Hi, any update on this, it would be really useful if this was back as a feature :)
I am sorry for late response, I also don't have admin permissions. Maybe @sigmavirus24 can give a hint on that?
It doesn't seem like there's interest in merging this.