mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-30 13:51:16 +00:00
Remove "blanket" from RUF100 README message (#2844)
This commit is contained in:
parent
32520ff07f
commit
d1cf0ee52b
3 changed files with 3 additions and 3 deletions
|
@ -1477,7 +1477,7 @@ For more, see [flake8-self](https://pypi.org/project/flake8-self/) on PyPI.
|
||||||
| RUF003 | ambiguous-unicode-character-comment | Comment contains ambiguous unicode character '{confusable}' (did you mean '{representant}'?) | 🛠 |
|
| RUF003 | ambiguous-unicode-character-comment | Comment contains ambiguous unicode character '{confusable}' (did you mean '{representant}'?) | 🛠 |
|
||||||
| RUF004 | keyword-argument-before-star-argument | Keyword argument `{name}` must come after starred arguments | |
|
| RUF004 | keyword-argument-before-star-argument | Keyword argument `{name}` must come after starred arguments | |
|
||||||
| RUF005 | unpack-instead-of-concatenating-to-collection-literal | Consider `{expr}` instead of concatenation | 🛠 |
|
| RUF005 | unpack-instead-of-concatenating-to-collection-literal | Consider `{expr}` instead of concatenation | 🛠 |
|
||||||
| RUF100 | unused-noqa | Unused blanket `noqa` directive | 🛠 |
|
| RUF100 | unused-noqa | Unused `noqa` directive | 🛠 |
|
||||||
|
|
||||||
<!-- End auto-generated sections. -->
|
<!-- End auto-generated sections. -->
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,6 @@ impl AlwaysAutofixableViolation for UnusedNOQA {
|
||||||
fn message(&self) -> String {
|
fn message(&self) -> String {
|
||||||
let UnusedNOQA { codes } = self;
|
let UnusedNOQA { codes } = self;
|
||||||
match codes {
|
match codes {
|
||||||
None => format!("Unused blanket `noqa` directive"),
|
|
||||||
Some(codes) => {
|
Some(codes) => {
|
||||||
let mut codes_by_reason = vec![];
|
let mut codes_by_reason = vec![];
|
||||||
if !codes.unmatched.is_empty() {
|
if !codes.unmatched.is_empty() {
|
||||||
|
@ -60,6 +59,7 @@ impl AlwaysAutofixableViolation for UnusedNOQA {
|
||||||
format!("Unused `noqa` directive ({})", codes_by_reason.join("; "))
|
format!("Unused `noqa` directive ({})", codes_by_reason.join("; "))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
None => format!("Unused blanket `noqa` directive"),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue