Skip to content

Remove custom media type for Pull Request Reviews API #638

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

Closed
gmlewis opened this issue May 11, 2017 · 13 comments
Closed

Remove custom media type for Pull Request Reviews API #638

gmlewis opened this issue May 11, 2017 · 13 comments
Assignees

Comments

@gmlewis
Copy link
Collaborator

gmlewis commented May 11, 2017

The custom media type application/vnd.github.black-cat-preview+json can be removed from go-github as the "Pull Request Reviews API" is no longer in preview but has become official.

See GitHub Developer announcement:
https://developer.github.com/changes/2017-05-09-end-black-cat-preview/

@varadarajana
Copy link
Contributor

@gmlewis please assign this to me

@varadarajana
Copy link
Contributor

@gmlewis @shurcooL Pull Requests have three categories - Reviews, ReviewComments and Review Requests. Is this change required for all of them. The documentation points are reviews only.

@dmitshur
Copy link
Member

I think it's all endpoints that currently set the custom application/vnd.github.black-cat-preview+json Accept header. They no longer need to.

varadarajana added a commit to varadarajana/go-github that referenced this issue May 15, 2017
varadarajana added a commit to varadarajana/go-github that referenced this issue May 15, 2017
varadarajana added a commit to varadarajana/go-github that referenced this issue May 15, 2017
varadarajana added a commit to varadarajana/go-github that referenced this issue May 15, 2017
bubg-dev pushed a commit to bubg-dev/go-github that referenced this issue Jun 16, 2017
The Pull Request Reviews API (include Review Requests) has become an
official part of GitHub API v3, so the preview API media type is no
longer needed. See announcement at
https://developer.github.com/changes/2017-05-09-end-black-cat-preview/.

Resolves google#638.
@swsnider
Copy link

This change breaks Enterprise users -- we don't have reviews out of preview yet :(.

@dmitshur
Copy link
Member

Thanks for reporting @swsnider.

Re-opening for further consideration.

How should we go about dealing with this, @gmlewis?

A short term solution is to revert this removal of the preview API.

However, a long term solution is deciding on our policy. Should latest master target GitHub.com
API only, or GitHub.com and GitHub Enterprise APIs? The challenge with doing the latter from what I can see is that their API chances/announcements are more difficult to track down for Enterprise API. But maybe I haven't looked hard enough.

@dmitshur dmitshur reopened this Aug 10, 2017
@swsnider
Copy link

The problem is that even after the Enterprise version with this fixed is released, you're typically still at the mercy of your IT org to upgrade your instance in a timely manner, so this may not be soluble by this project :(.

@dmitshur
Copy link
Member

Right. So it might be the case that a better/more viable solution is to, unfortunately, use an older version of go-github via vendoring.

@swsnider
Copy link

Yeah, that's what I'm doing for now

@elliott-beach
Copy link
Contributor

elliott-beach commented Aug 20, 2017

I think the "good-for-beginners" label could be removed from this, unless there is a way for a random person like me to solve it?

@gmlewis
Copy link
Collaborator Author

gmlewis commented Aug 21, 2017

I had a talk with @willnorris about this, and I believe our resolution was that semantic versioning (#376) would be the best way to support GitHub Enterprise API users (and that they would need to vendor the version that best supported their use-case), and that the latest master target the latest GitHub API.

As such, I think the "good-for-beginners" label still holds for this issue.

@willnorris
Copy link
Collaborator

We can't help IT departments that are slow to upgrade, and vendoring (together with semver) is the right solution there.

But I kinda like the policy of not removing preview media types until they have been released in GitHub Enterprise (assuming we can track that without too much trouble). We could go ahead and create issues like this when APIs come out of preview for github.com, and apply a special issue label, but don't actually remove the code. Then, when the next GitHub Enterprise version is released, we go through the issues to see which ones we can remove. It's a little bit of manual work but it's only done periodically.

@dmitshur
Copy link
Member

As such, I think the "good-for-beginners" label still holds for this issue.

Note, the original task of removing the media type has already been done in 1151660, @gmlewis. I've reopened the issue only to discuss the outcome regarding Enterprise not having support for this yet. Aside from discussion, this issue isn't actionable, so I'll remove that label.

@dmitshur
Copy link
Member

It also sounds like we've come to a conclusion about the long term solution. Thanks @gmlewis and @willnorris. Further discussion about semver and tagging can be resumed in #376. I'll close this issue, but feel to continue discussion there, or open a new issue if there's something specific to address.

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

No branches or pull requests

6 participants