Improve docs for some pycodestyle rules (#14517)

This commit is contained in:
Alex Waygood 2024-11-21 17:26:06 +00:00 committed by GitHub
parent 2efa3fbb62
commit 2b8b1ef178
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 3 deletions

View File

@ -12,8 +12,8 @@ use crate::settings::LinterSettings;
/// ## Why is this bad?
/// Overlong lines can hurt readability. [PEP 8], for example, recommends
/// limiting lines to 79 characters. By default, this rule enforces a limit
/// of 88 characters for compatibility with Black, though that limit is
/// configurable via the [`line-length`] setting.
/// of 88 characters for compatibility with Black and the Ruff formatter,
/// though that limit is configurable via the [`line-length`] setting.
///
/// In the interest of pragmatism, this rule makes a few exceptions when
/// determining whether a line is overlong. Namely, it:

View File

@ -169,7 +169,8 @@ impl AlwaysFixableViolation for TabAfterComma {
/// Checks for extraneous whitespace after a comma.
///
/// ## Why is this bad?
/// According to the `black` code style, commas should be followed by a single space.
/// Consistency is good. This rule helps ensure you have a consistent
/// formatting style across your project.
///
/// ## Example
/// ```python