From 930306f52c76e10d32853e44943ecd5a238dabef Mon Sep 17 00:00:00 2001 From: Brent Westbrook Date: Wed, 28 Jan 2026 11:15:18 -0500 Subject: [PATCH] Stabilize `RUF061` I made two small tweaks to the docs, but this otherwise looked good to me. --- .../src/rules/ruff/rules/legacy_form_pytest_raises.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/crates/ruff_linter/src/rules/ruff/rules/legacy_form_pytest_raises.rs b/crates/ruff_linter/src/rules/ruff/rules/legacy_form_pytest_raises.rs index b48a2520f2376..0b65d60727d95 100644 --- a/crates/ruff_linter/src/rules/ruff/rules/legacy_form_pytest_raises.rs +++ b/crates/ruff_linter/src/rules/ruff/rules/legacy_form_pytest_raises.rs @@ -11,10 +11,11 @@ use std::fmt; use crate::{FixAvailability, Violation, checkers::ast::Checker}; /// ## What it does -/// Checks for non-contextmanager use of `pytest.raises`, `pytest.warns`, and `pytest.deprecated_call`. +/// Checks for non-context-manager use of `pytest.raises`, `pytest.warns`, and `pytest.deprecated_call`. /// /// ## Why is this bad? -/// The context-manager form is more readable, easier to extend, and supports additional kwargs. +/// The context-manager form is more readable, easier to extend, and supports additional keyword +/// arguments. /// /// ## Example /// ```python @@ -44,7 +45,7 @@ use crate::{FixAvailability, Violation, checkers::ast::Checker}; /// - [`pytest` documentation: `pytest.warns`](https://docs.pytest.org/en/latest/reference/reference.html#pytest-warns) /// - [`pytest` documentation: `pytest.deprecated_call`](https://docs.pytest.org/en/latest/reference/reference.html#pytest-deprecated-call) #[derive(ViolationMetadata)] -#[violation_metadata(preview_since = "0.12.0")] +#[violation_metadata(stable_since = "0.15.0")] pub(crate) struct LegacyFormPytestRaises { context_type: PytestContextType, }