-
-
Notifications
You must be signed in to change notification settings - Fork 39
Closed
Description
Please improve the Exception handling in the code to help the user do troubelshooting.
Please also consider actual documenation for this package.
e.g.:
My code:
from adguardhome import AdGuardHome
import asyncio
ipAddress = "192.168.1.100"
async def main():
"""Show example how to get status of your AdGuard Home instance."""
async with AdGuardHome(ipAddress) as adguard:
version = await adguard.version()
print("AdGuard version:", version)
active = await adguard.protection_enabled()
active = "Yes" if active else "No"
print("Protection enabled?", active)
if not active:
print("AdGuard Home protection disabled. Enabling...")
await adguard.enable_protection()
if __name__ == "__main__":
loop = asyncio.get_event_loop()
loop.run_until_complete(main())
Metadata
Metadata
Assignees
Labels
No labels
