Skip to content

Commit

Permalink
Switch to python 3.10 and add 3.11 support
Browse files Browse the repository at this point in the history
Signed-off-by: Álvaro Fernández Rojas <[email protected]>
  • Loading branch information
Noltari committed Feb 24, 2023
1 parent 671e438 commit f6c29c0
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
- pull_request

env:
DEFAULT_PYTHON: "3.9"
DEFAULT_PYTHON: "3.10"

jobs:
black:
Expand Down Expand Up @@ -100,7 +100,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10"]
python-version: ["3.9", "3.10", "3.11"]
steps:
- name: Check out code from GitHub
uses: actions/checkout@v3
Expand Down
17 changes: 8 additions & 9 deletions aioqsw/localapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,10 +148,9 @@ async def http_request(
resp_json = None
try:
resp_json = await resp.json()
_LOGGER.debug("aiohttp response: %s", resp_json)
except ContentTypeError as err:
raise InvalidResponse from err
else:
_LOGGER.debug("aiohttp response: %s", resp_json)

if resp.status == 401:
raise LoginError("Login error @ {method} /{path}")
Expand Down Expand Up @@ -383,13 +382,13 @@ async def update(self) -> None:
except QswError as err:
system_sensor.cancel()
raise err
else:
try:
self.system_sensor = SystemSensor(await system_sensor)
except InternalServerError as err:
if self._first_update:
raise err
_LOGGER.warning(err)

try:
self.system_sensor = SystemSensor(await system_sensor)
except InternalServerError as err:
if self._first_update:
raise err
_LOGGER.warning(err)

self._first_update = False

Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Topic :: Home Automation",
],
)

0 comments on commit f6c29c0

Please sign in to comment.