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

B015: prepend "assert" and fix verb tense #150

Merged
merged 1 commit into from
Nov 29, 2020

Conversation

stevepiercy
Copy link
Contributor

Copy link
Collaborator

@cooperlees cooperlees left a comment

Choose a reason for hiding this comment

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

Sure, might click some people's brains to understand the lint better. So thanks.

@@ -118,7 +118,7 @@ instead of ``except (SomeError,):``.
Write ``except Exception:``, which catches exactly the same exceptions.

**B015**: Pointless comparison. This comparison does nothing but
wastes CPU instructions. Remove it.
waste CPU instructions. Either prepend ``assert`` or remove it.
Copy link
Collaborator

Choose a reason for hiding this comment

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

FWIW, assert could possibly not always technically be the right thing too ...

@cooperlees cooperlees merged commit 836139b into PyCQA:master Nov 29, 2020
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