Skip to content

Commit 4c5bf00

Browse files
committed
Do not report E704 in the default configuration; issue #277
1 parent 999e335 commit 4c5bf00

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

CHANGES.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,11 @@ Changelog
77

88
* Report E731 for lambda assignment. (Issue #277)
99

10-
* Report E704 for one-liner def instead of E701. (Issue #277)
10+
* Report E704 for one-liner def instead of E701.
11+
Do not report this error in the default configuration. (Issue #277)
1112

1213
* Replace codes E111, E112 and E113 with codes E114, E115 and E116
13-
for wrong indentation of comments. (Issue #274)
14+
for bad indentation of comments. (Issue #274)
1415

1516
* Report E266 instead of E265 when the block comment starts with
1617
multiple ``#``. (Issue #270)

docs/intro.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ This is the current list of error and warning codes:
313313
+----------+----------------------------------------------------------------------+
314314
| E703 | statement ends with a semicolon |
315315
+----------+----------------------------------------------------------------------+
316-
| E704 | multiple statements on one line (def) |
316+
| E704 (*) | multiple statements on one line (def) |
317317
+----------+----------------------------------------------------------------------+
318318
| E711 (^) | comparison to None should be 'if cond is None:' |
319319
+----------+----------------------------------------------------------------------+
@@ -367,7 +367,7 @@ This is the current list of error and warning codes:
367367

368368

369369
**(*)** In the default configuration, the checks **E123**, **E133**, **E226**,
370-
**E241** and **E242** are ignored because they are not rules unanimously
370+
**E241**, **E242** and **E704** are ignored because they are not rules unanimously
371371
accepted, and `PEP 8`_ does not enforce them. The check **E133** is mutually
372372
exclusive with check **E123**. Use switch ``--hang-closing`` to report **E133**
373373
instead of **E123**.

pep8.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
from ConfigParser import RawConfigParser
6565

6666
DEFAULT_EXCLUDE = '.svn,CVS,.bzr,.hg,.git,__pycache__'
67-
DEFAULT_IGNORE = 'E123,E226,E24'
67+
DEFAULT_IGNORE = 'E123,E226,E24,E704'
6868
if sys.platform == 'win32':
6969
DEFAULT_CONFIG = os.path.expanduser(r'~\.pep8')
7070
else:

testsuite/test_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ def parse_argv(argstring):
178178

179179
options = parse_argv('').options
180180
self.assertEqual(options.select, ())
181-
self.assertEqual(options.ignore, ('E123', 'E226', 'E24'))
181+
self.assertEqual(options.ignore, ('E123', 'E226', 'E24', 'E704'))
182182

183183
options = parse_argv('--doctest').options
184184
self.assertEqual(options.select, ())

0 commit comments

Comments
 (0)