Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missed required_conversation_resolution field in branch protection rules #1945

Closed
g4s8 opened this issue Jul 7, 2021 · 0 comments · Fixed by #1946
Closed

Missed required_conversation_resolution field in branch protection rules #1945

g4s8 opened this issue Jul 7, 2021 · 0 comments · Fixed by #1946

Comments

@g4s8
Copy link
Contributor

g4s8 commented Jul 7, 2021

GitHub added a new option for branch protection rules: Require conversation resolution before merging, v3 API also includes this new field as required_conversation_resolution (see example below). But current version (v36) of go-github doesn't include this field in protection struct.

Example API call:

{
  "url": "https://api.github.com/repos/g4s8/gitstrap/branches/master/protection", 
  "required_status_checks": {
    "url": "https://api.github.com/repos/g4s8/gitstrap/branches/master/protection/required_status_checks",
    "strict": true,
    "contexts": [
      "build",
      "lint",
      "test"
    ],
    "contexts_url": "https://api.github.com/repos/g4s8/gitstrap/branches/master/protection/required_status_checks/contexts"
  },
  "required_pull_request_reviews": {
    "url": "https://api.github.com/repos/g4s8/gitstrap/branches/master/protection/required_pull_request_reviews",
    "dismiss_stale_reviews": true,
    "require_code_owner_reviews": false,
    "required_approving_review_count": 1
  },
  "enforce_admins": {
    "url": "https://api.github.com/repos/g4s8/gitstrap/branches/master/protection/enforce_admins",
    "enabled": false
  },
  "required_linear_history": {
    "enabled": true
  },
  "allow_force_pushes": {
    "enabled": false
  },
  "allow_deletions": {
    "enabled": false
  },
  "required_conversation_resolution": {
    "enabled": false
  }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant