diff --git a/docs/configuration.md b/docs/configuration.md index b41204254f..b210376bfb 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -394,8 +394,9 @@ i = 1 # noqa: E741, F841 x = 1 # noqa ``` -Note that, for multi-line strings, the `noqa` directive should come at the end of the string, and -will apply to the entire string, like so: +For multi-line strings (like docstrings), +the `noqa` directive should come at the end of the string (after the closing triple quote), +and will apply to the entire string, like so: ```python """Lorem ipsum dolor sit amet. diff --git a/docs/tutorial.md b/docs/tutorial.md index 145a90c1ea..46e4c22516 100644 --- a/docs/tutorial.md +++ b/docs/tutorial.md @@ -205,6 +205,11 @@ def sum_even_numbers(numbers: List[int]) -> int: return sum(num for num in numbers if num % 2 == 0) ``` +For more in-depth instructions on ignoring errors, +please see [_Configuration_](configuration.md#error-suppression). + +### Adding Rules + When enabling a new rule on an existing codebase, you may want to ignore all _existing_ violations of that rule and instead focus on enforcing it going forward.