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

Do not raise when a webhook worker experiences a remote server error #811

Merged
merged 1 commit into from
Apr 2, 2024

Conversation

brucebolt
Copy link
Member

This application returns the link checking results to the requesting application through a webhook.

In some cases, the remote server will respond with an error (e.g. a timeout). We don't need to log these to Sentry, since they are outside of this application's control.

Therefore rescuing from the Faraday::ServerError raise that can occur in this worker.

Trello card

@brucebolt brucebolt changed the title Do not raise when a webhook experiences a remote server error Do not raise when a webhook worker experiences a remote server error Apr 2, 2024
@brucebolt brucebolt force-pushed the do-not-log-server-error branch from 664bc0d to 7b53217 Compare April 2, 2024 09:39
Copy link
Contributor

@JonathanHallam JonathanHallam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice one, thanks!

This application returns the link checking results to the requesting
application through a webhook.

In some cases, the remote server will respond with an error (e.g. a
timeout or some other 5xx status code). We don't need to log these to
Sentry, since they are outside of this application's control.

Therefore rescuing from the `Faraday::ServerError` raise that can occur
in this worker.
@brucebolt brucebolt force-pushed the do-not-log-server-error branch from 7b53217 to edc1aa9 Compare April 2, 2024 10:02
@brucebolt
Copy link
Member Author

Thanks @JonathanHallam. Would you mind looking again, since I forgot to commit the test 🤦‍♂️!

Copy link
Contributor

@JonathanHallam JonathanHallam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, should have spotted that there weren't tests. Baby has a cold, I have not really slept 😵‍💫

@brucebolt brucebolt merged commit 800e45e into main Apr 2, 2024
12 checks passed
@brucebolt brucebolt deleted the do-not-log-server-error branch April 2, 2024 10:32
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 this pull request may close these issues.

2 participants