From 5485917b3d5874f04efcc295d005143a7d8950ed Mon Sep 17 00:00:00 2001 From: Devyn Collier Johnson Date: Sun, 7 Oct 2018 00:03:39 -0500 Subject: [PATCH] PyLint Comments Work With Other Linter Comments This is the solution for [#2297](https://github.com/PyCQA/pylint/issues/2297), [#2470](https://github.com/PyCQA/pylint/issues/2470), and [#2485](https://github.com/PyCQA/pylint/issues/2485). --- pylint/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pylint/utils.py b/pylint/utils.py index 76afdea096..6493f131e9 100644 --- a/pylint/utils.py +++ b/pylint/utils.py @@ -81,7 +81,7 @@ # Allow stopping after the first semicolon/hash encountered, # so that an option can be continued with the reasons # why it is active or disabled. -OPTION_RGX = re.compile(r"\s*#.*\bpylint:\s*([^;#]+)[;#]{0,1}") +OPTION_RGX = re.compile(r'.*#\s*pylint:\s*([^;#]+)[;#]?.*') # The line/node distinction does not apply to fatal errors and reports. _SCOPE_EXEMPT = "FR"