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

Add custom exception for the HTTP 451 response (DMCA Notice) #1237

Closed
2 tasks
ryangribble opened this issue Apr 3, 2016 · 1 comment
Closed
2 tasks

Add custom exception for the HTTP 451 response (DMCA Notice) #1237

ryangribble opened this issue Apr 3, 2016 · 1 comment
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone

Comments

@ryangribble
Copy link
Contributor

Summary

As per this blog post

GitHub API will now return a HTTP 451 response (rather than a 403) when a repository or gist cannot be accessed due to a DMCA notice.

Tips for Octokit Implementation

In octokit, some key HTTP exceptions are represented by specific named exceptions (eg ForbiddenException, which the HandleErrors() function in Connection.cs will throw when those HTTP response error codes are encountered.

  • A specific exception class should be added for this new 451 response, and mappings added to the HandleErrors logic so it is thrown when encountered
  • Unit tests should be updated/implemented, similar to ForbiddenException

Working on this issue

This issue has been flagged as up-for-grabs as it is a reasonably easy issue for a new contributor to pick up, and be guided through the process of contributing to octokit
(that said, if an existing contributor wants to work on this, by all means go for it!)

Please comment here if you want to take this issue.

Please read and follow the CONTRIBUTING guide guide and if you need any help, just ask! Don't be afraid to open a [WIP] (work in progress) Pull Request once you've started implementing the changes

@devkhan
Copy link
Contributor

devkhan commented Apr 11, 2016

Can be closed now.

@nickfloyd nickfloyd added Status: Up for grabs Issues that are ready to be worked on by anyone and removed up-for-grabs labels Oct 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone
Projects
None yet
Development

No branches or pull requests

4 participants