switchbot-api 2.13.0__tar.gz → 2.13.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: switchbot_api
3
- Version: 2.13.0
3
+ Version: 2.13.1
4
4
  Summary: An asynchronous library to use Switchbot API
5
5
  License: MIT
6
6
  License-File: LICENSE
@@ -14,6 +14,7 @@ Classifier: Programming Language :: Python :: 3.11
14
14
  Classifier: Programming Language :: Python :: 3.12
15
15
  Classifier: Programming Language :: Python :: 3.13
16
16
  Classifier: Programming Language :: Python :: 3.14
17
+ Classifier: Programming Language :: Python :: 3.15
17
18
  Requires-Dist: aiohttp (>=3.0.0)
18
19
  Requires-Dist: pycryptodome (>=3.23.0,<4.0.0)
19
20
  Project-URL: Repository, https://github.com/SeraphicCorp/py-switchbot-api
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "switchbot_api"
3
- version = "2.13.0"
3
+ version = "2.13.1"
4
4
  description = "An asynchronous library to use Switchbot API"
5
5
  authors = ["Ravaka Razafimanantsoa <contact@ravaka.dev>"]
6
6
  license = "MIT"
@@ -239,9 +239,11 @@ class SwitchBotAPI:
239
239
  except (
240
240
  ClientError,
241
241
  ClientResponseError,
242
- socket.gaierror,
243
242
  ) as exception:
244
- msg = "Error occurred while communicating with the SwitchBot API"
243
+ msg = f"Error occurred while communicating, Status Code: {exception}"
244
+ raise SwitchBotConnectionError(msg) from exception
245
+ except socket.gaierror as exception:
246
+ msg = "DNS resolution failed."
245
247
  raise SwitchBotConnectionError(msg) from exception
246
248
  if response.status == 403:
247
249
  raise SwitchBotAuthenticationError
File without changes
File without changes