diff --git a/homeassistant/components/plex/server.py b/homeassistant/components/plex/server.py index eab1d086d4c..7f9c2545032 100644 --- a/homeassistant/components/plex/server.py +++ b/homeassistant/components/plex/server.py @@ -203,7 +203,7 @@ class PlexServer: config_entry_update_needed = True else: # pylint: disable-next=raise-missing-from - raise Unauthorized( # noqa: TRY200 + raise Unauthorized( # noqa: B904 "New certificate cannot be validated" " with provided token" ) diff --git a/homeassistant/util/loop.py b/homeassistant/util/loop.py index 6ee554a3ef3..bebd399a5cd 100644 --- a/homeassistant/util/loop.py +++ b/homeassistant/util/loop.py @@ -93,7 +93,7 @@ def raise_for_blocking_call( return if found_frame is None: - raise RuntimeError( # noqa: TRY200 + raise RuntimeError( # noqa: B904 f"Caught blocking call to {func.__name__} " f"with args {mapped_args.get('args')} " f"in {offender_filename}, line {offender_lineno}: {offender_line} " diff --git a/pyproject.toml b/pyproject.toml index 84233aba242..7d6fb154375 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -772,6 +772,7 @@ select = [ "RUF033", # __post_init__ method with argument defaults "RUF034", # Useless if-else condition "RUF100", # Unused `noqa` directive + "RUF101", # noqa directives that use redirected rule codes "RUF200", # Failed to parse pyproject.toml: {message} "S102", # Use of exec detected "S103", # bad-file-permissions