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

Flake8: remove E111, E114, E116, E117, E121 #4557

Merged
merged 4 commits into from May 8, 2020

Conversation

elacuesta
Copy link
Member

  • E111: indentation is not a multiple of four
  • E114: indentation is not a multiple of four (comment) - unused
  • E116: unexpected indentation (comment)
  • E117: over-indented - unused
  • E121: continuation line under-indented for hanging indent

if not(response is None or text is None):
raise ValueError('%s.__init__() received both response and text'
% self.__class__.__name__)
if response is not None and text is not None:
Copy link
Member Author

Choose a reason for hiding this comment

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

This is more readable IMHO. De Morgan to the rescue!

@codecov
Copy link

codecov bot commented May 8, 2020

Codecov Report

Merging #4557 into master will decrease coverage by 0.02%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #4557      +/-   ##
==========================================
- Coverage   84.51%   84.49%   -0.03%     
==========================================
  Files         164      164              
  Lines        9904     9904              
  Branches     1482     1482              
==========================================
- Hits         8370     8368       -2     
- Misses       1266     1267       +1     
- Partials      268      269       +1     
Impacted Files Coverage Δ
scrapy/pipelines/files.py 59.93% <100.00%> (ø)
scrapy/selector/unified.py 100.00% <100.00%> (ø)
scrapy/core/downloader/__init__.py 89.47% <0.00%> (-1.51%) ⬇️

@kmike kmike merged commit 707f591 into scrapy:master May 8, 2020
2 checks passed
@kmike
Copy link
Member

kmike commented May 8, 2020

👍

@elacuesta elacuesta deleted the flake8-remove-e1xx branch May 8, 2020 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants