python-jebao 0.1.0__tar.gz → 0.1.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: python-jebao
3
- Version: 0.1.0
3
+ Version: 0.1.1
4
4
  Summary: Python library for controlling Jebao aquarium pumps
5
5
  Home-page: https://github.com/jrigling/python-jebao
6
6
  Author: Justin Rigling
@@ -16,7 +16,7 @@ from .const import (
16
16
  MODEL_MD44,
17
17
  )
18
18
 
19
- __version__ = "0.1.0"
19
+ __version__ = "0.1.1"
20
20
 
21
21
  __all__ = [
22
22
  "JebaoDevice",
@@ -6,6 +6,7 @@ from typing import Optional
6
6
  from .const import DEFAULT_TIMEOUT, DeviceState
7
7
  from .exceptions import JebaoConnectionError
8
8
  from .protocol import JebaoProtocol
9
+ from .retry import async_retry
9
10
 
10
11
  _LOGGER = logging.getLogger(__name__)
11
12
 
@@ -99,6 +100,7 @@ class JebaoDevice:
99
100
  await self._protocol.disconnect()
100
101
  _LOGGER.info("Disconnected from %s", self.host)
101
102
 
103
+ @async_retry(max_attempts=3, delay=0.5)
102
104
  async def update(self, timeout: float = DEFAULT_TIMEOUT) -> None:
103
105
  """Update device status.
104
106
 
@@ -40,6 +40,7 @@ class MDP20000Device(JebaoDevice):
40
40
  super().__init__(host, port, device_id, MODEL_MDP20000)
41
41
  self._feed_duration: int = 1 # Last configured feed duration
42
42
 
43
+ @async_retry(max_attempts=3, delay=0.5)
43
44
  async def ensure_manual_mode(self, timeout: float = COMMAND_TIMEOUT) -> None:
44
45
  """Ensure device is in manual mode.
45
46
 
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "python-jebao"
7
- version = "0.1.0"
7
+ version = "0.1.1"
8
8
  description = "Python library for controlling Jebao aquarium pumps"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-jebao
3
- Version: 0.1.0
3
+ Version: 0.1.1
4
4
  Summary: Python library for controlling Jebao aquarium pumps
5
5
  Home-page: https://github.com/jrigling/python-jebao
6
6
  Author: Justin Rigling
File without changes
File without changes
File without changes
File without changes