fix(driver): refuse media controls when not connected
driver / standard (pull_request) Successful in 16s
driver / lint (pull_request) Successful in 15s
driver / types (pull_request) Successful in 1m18s
driver / test (3.12) (pull_request) Successful in 3m14s
driver / test (3.13) (pull_request) Successful in 2m54s
driver / lowest (pull_request) Successful in 2m23s
driver / build (pull_request) Successful in 35s
driver / security (pull_request) Successful in 1m11s
CI / driver (pull_request) Successful in 4m53s
driver / publish (pull_request) Skipped

play() and the other controls returned silently without a device, so
a control that did nothing looked like it had worked. They now raise
ConnectionClosedException. get_arp_table() takes NAPALM's vrf
argument, and the module docstring moves above the imports so
__doc__ is set again.

The wired-speaker part of the issue stays open: SoCo's
deviceProperties is a UPnP service, not a dict with WifiMode, so
renaming the attribute alone would still never report eth0.

Refs #2
This commit is contained in:
Christian Manivong committed 2026-11-01 21:53:55 +01:00
1 parent 0ed6a7093d
commit 322b7cd688
3 files changed
+61 -33

No files matched your search

+7
View File
@@ -12,6 +12,13 @@ All notable changes to this driver. The format follows
- The floor on napalm is 5.1: older releases import `pkg_resources`, which a Python
3.12 venv no longer has.
### Fixed
- `play()`, `pause()`, `stop()`, `next_track()`, `previous_track()`, `set_volume()`
and `set_mute()` raise `ConnectionClosedException` when the driver is not connected,
instead of returning as if the speaker had done it (#2).
- `get_arp_table()` takes NAPALM's `vrf` argument (#2).
- The driver module carries its docstring again (`__doc__` was `None`) (#2).
## [0.3.0] - 2026-10-23
The first release on PyPI.