mirror of
https://github.com/python-kasa/python-kasa.git
synced 2025-10-08 16:38:01 +00:00
Improve CLI Discovery output (#583)
- Show discovery results for unsupported devices and devices that fail to authenticate. - Rename `--show-unsupported` to `--verbose`. - Remove separate `--timeout` parameter from cli discovery so it's not confused with `--timeout` now added to cli command. - Add tests.
This commit is contained in:
@@ -9,6 +9,10 @@ class SmartDeviceException(Exception):
|
||||
class UnsupportedDeviceException(SmartDeviceException):
|
||||
"""Exception for trying to connect to unsupported devices."""
|
||||
|
||||
def __init__(self, *args, discovery_result=None):
|
||||
self.discovery_result = discovery_result
|
||||
super().__init__(args)
|
||||
|
||||
|
||||
class AuthenticationException(SmartDeviceException):
|
||||
"""Base exception for device authentication errors."""
|
||||
|
Reference in New Issue
Block a user