-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Handle 401, 403 and 404 status codes when hitting GitHub for webhook #4805
Conversation
Looks reasonable, what else is needed here? |
Changes are good, but I did them only for GitHub in this PR. I need to extend this to all the services and because of this, I wanted to refactor a little those files to share more code. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@humitos merge this now, and create an issue for the others?
You say it, you have it! :) Issue to track the rest of this work at #5092 |
53928f0
to
e17d0cd
Compare
Codecov Report
@@ Coverage Diff @@
## master #4805 +/- ##
==========================================
- Coverage 76.87% 76.23% -0.64%
==========================================
Files 158 158
Lines 9997 10037 +40
Branches 1255 1268 +13
==========================================
- Hits 7685 7652 -33
- Misses 1980 2042 +62
- Partials 332 343 +11
|
1 similar comment
Codecov Report
@@ Coverage Diff @@
## master #4805 +/- ##
==========================================
- Coverage 76.87% 76.23% -0.64%
==========================================
Files 158 158
Lines 9997 10037 +40
Branches 1255 1268 +13
==========================================
- Hits 7685 7652 -33
- Misses 1980 2042 +62
- Partials 332 343 +11
|
9ea2f78
to
2ae1c26
Compare
This is a work in progress PR.
All of our integrations are not handling these error codes: 401, 403 and 404. All of them are being logged as errors in our application. This PR handle them to log as info instead of an error (via the else: clause).
Also, this code may need to be repeated across all the integrations and twice on each. So, maybe it's possible to refactor this all together: https://github.com/rtfd/readthedocs-corporate/issues/372