Skip to content

Don't depend on specific data when catching exception #5326

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

Merged
merged 2 commits into from
Feb 21, 2019

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented Feb 20, 2019

We are catching all exceptions here,
but we are depending on self.project and self.version
be correctly returned from the api.
This doesn't always happen, and it's raising another error.

We should catch more specific errors, but we are not seeing those errors bc of this error (hope that makes sense 👀 )

Sentry issue https://sentry.io/organizations/read-the-docs/issues/754905187/?project=148442&referrer=RegressionActivityEmail&statsPeriod=14d

We are catching all exceptions here,
but we are depending on self.project and self.version
be correctly returned from the api.
This doesn't always happens, and it's raising another error.
@stsewd stsewd requested a review from a team February 20, 2019 22:36
@stsewd stsewd changed the title Don't depend or specific data Don't depend on specific data when catching exception Feb 20, 2019
Copy link
Member

@humitos humitos left a comment

Choose a reason for hiding this comment

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

Make sense.

I think we have other places where this also happens, too. We can take care of them in the next iteration.

@ericholscher ericholscher merged commit ed8dd29 into readthedocs:master Feb 21, 2019
@stsewd stsewd deleted the protect-against-api-failure branch February 21, 2019 11:25
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.

3 participants