File tree Expand file tree Collapse file tree 2 files changed +4
-8
lines changed
Expand file tree Collapse file tree 2 files changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ default_language_version:
55repos :
66 # Run manually in CI skipping the branch checks
77 - repo : https://github.com/astral-sh/ruff-pre-commit
8- rev : v0.14.14
8+ rev : v0.15.2
99 hooks :
1010 - id : ruff
1111 name : " Ruff check"
Original file line number Diff line number Diff line change @@ -58,12 +58,8 @@ def __init__(
5858 self .api_version : int = 8
5959
6060 parsed_host = urlparse (host )
61- scheme = (
62- parsed_host .scheme
63- if parsed_host .scheme
64- else ("https" if use_ssl else "http" )
65- )
66- hostname = parsed_host .hostname if parsed_host .hostname else host
61+ scheme = parsed_host .scheme or ("https" if use_ssl else "http" )
62+ hostname = parsed_host .hostname or host
6763
6864 self .base_url = f"{ scheme } ://{ hostname } "
6965
@@ -309,7 +305,7 @@ async def _request_json(
309305 )
310306 if err .status in [401 , 403 ]:
311307 raise AirOSConnectionAuthenticationError from err
312- if err .status in [ 404 ] :
308+ if err .status == 404 :
313309 raise AirOSUrlNotFoundError from err
314310 raise AirOSConnectionSetupError from err
315311 except (TimeoutError , aiohttp .ClientError ) as err :
You can’t perform that action at this time.
0 commit comments