Add link to regex101 for noqa regex

This provides a step by step doc for the regular expression, and makes iterating on it much easier
This commit is contained in:
Tomer Keren 2018-12-27 18:28:08 +02:00
parent 08492ee857
commit 445d19b9de

View file

@ -35,6 +35,7 @@ NOQA_INLINE_REGEXP = re.compile(
# We do not want to capture the ``: `` that follows ``noqa``
# We do not care about the casing of ``noqa``
# We want a comma-separated list of errors
# https://regex101.com/r/4XUuax/2 full explenation of the regex
r"# noqa(?::[\s]?(?P<codes>([A-Z][0-9]+(?:[,\s]+)?)+))?",
re.IGNORECASE,
)