Skip to content

Commit cb4ceb0

Browse files
fix #7 - Exception is raised when the Dice is flipped but no custom flip handler attached
1 parent 133a3f7 commit cb4ceb0

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
Use the GoDice Python API to integrate GoDice functionality into your own Python applications
77

8-
![PyPI - Version](https://img.shields.io/pypi/v/godice)
8+
[![PyPI version](https://badge.fury.io/py/godice.svg)](https://pypi.org/project/godice)
99

1010
**Supported features:**
1111

godice/dice.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,9 @@ def __init__(self, ble_client) -> None:
4141
self._color_upd_q = asyncio.Queue()
4242
self._battery_lvl_upd_q = asyncio.Queue()
4343
self._xyz_interpret_fn = None
44-
self._nop_cb = lambda _: None
45-
self._position_upd_cb = self._nop_cb
44+
async def _noop_cb(_num, _stab_descr):
45+
pass
46+
self._position_upd_cb = _noop_cb
4647

4748
async def connect(self):
4849
await self._client.connect()

0 commit comments

Comments
 (0)