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

Initialize local variable before using it #5342

Merged
merged 2 commits into from Feb 25, 2019

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented Feb 22, 2019

If the try..except block fails and there is not
results, we end up with updated undefined.

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

If the try..except block fails and there is not
results, we end up with `updated` undefined.
@stsewd stsewd requested a review from a team February 22, 2019 16:59
Copy link
Member

@ericholscher ericholscher left a comment

Choose a reason for hiding this comment

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

Surprised tests or linting didn't catch this. Is there a good way to catch this kind of stuff in the future?

@stsewd
Copy link
Member Author

stsewd commented Feb 22, 2019

Surprised tests or linting didn't catch this. Is there a good way to catch this kind of stuff in the future?

More tests/coverage p: This is still tricky for static analyzers I guess

@humitos humitos merged commit fab3be9 into readthedocs:master Feb 25, 2019
@stsewd stsewd deleted the initialize-local-variable branch February 25, 2019 13:06
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.

None yet

3 participants