From a3ec3df0c883d0655beadb44e3873c25bc38d06c Mon Sep 17 00:00:00 2001 From: Bruno Oliveira Date: Mon, 23 Oct 2017 18:19:15 -0200 Subject: [PATCH] Add E722 and E741 flake errors to the ignore list Also fixed 'E704 multiple statements on one line (def)' in python_api --- _pytest/python_api.py | 3 ++- tox.ini | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/_pytest/python_api.py b/_pytest/python_api.py index b73e0457c..a3cf1c8cb 100644 --- a/_pytest/python_api.py +++ b/_pytest/python_api.py @@ -217,7 +217,8 @@ class ApproxScalar(ApproxBase): absolute tolerance or a relative tolerance, depending on what the user specified or which would be larger. """ - def set_default(x, default): return x if x is not None else default + def set_default(x, default): + return x if x is not None else default # Figure out what the absolute tolerance should be. ``self.abs`` is # either None or a value specified by the user. diff --git a/tox.ini b/tox.ini index 9245ff418..33e5fa02c 100644 --- a/tox.ini +++ b/tox.ini @@ -213,3 +213,8 @@ filterwarnings = [flake8] max-line-length = 120 exclude = _pytest/vendored_packages/pluggy.py +ignore= + # do not use bare except' + E722 + # ambiguous variable name 'l' + E741