Revert "fix: Hopefully fixes all problems"
This reverts commit c85173e0e9
.
This commit is contained in:
3
.flake8
3
.flake8
@@ -1,3 +1,4 @@
|
||||
[flake8]
|
||||
exclude = .venv,.git,__pycache__,docs/source/conf.py,old,build,dist
|
||||
max-line-length = 127
|
||||
exclude = .git,__pycache__,.venv,venv,.pytest_cache
|
||||
ignore = E203,W503,E501
|
||||
|
@@ -20,7 +20,6 @@ jobs:
|
||||
with:
|
||||
python-version: '3.13'
|
||||
|
||||
# FIXED: Added cache configuration
|
||||
- name: Cache pip dependencies
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
|
@@ -3,7 +3,7 @@ from homeassistant.const import Platform
|
||||
|
||||
# Integration metadata
|
||||
DOMAIN = "adguard_hub"
|
||||
MANUFACTURER = "AdGuard"
|
||||
MANUFACTURER = "AdGuard" # FIXED: Added missing MANUFACTURER constant
|
||||
SCAN_INTERVAL = 30
|
||||
DEFAULT_PORT = 3000
|
||||
DEFAULT_SSL = False
|
||||
|
@@ -35,6 +35,7 @@ class AdGuardControlHubServices:
|
||||
|
||||
def register_services(self) -> None:
|
||||
"""Register services."""
|
||||
# FIXED: All service constants are now properly defined
|
||||
self.hass.services.register(
|
||||
DOMAIN,
|
||||
SERVICE_BLOCK_SERVICES,
|
||||
|
@@ -52,7 +52,7 @@ class AdGuardProtectionSwitch(CoordinatorEntity, SwitchEntity):
|
||||
return DeviceInfo(
|
||||
identifiers={(DOMAIN, "adguard_home")},
|
||||
name="AdGuard Home",
|
||||
manufacturer=MANUFACTURER,
|
||||
manufacturer=MANUFACTURER, # FIXED: Now uses imported MANUFACTURER
|
||||
model="AdGuard Home",
|
||||
configuration_url=self.api.base_url,
|
||||
)
|
||||
|
@@ -16,7 +16,7 @@ addopts = [
|
||||
"--cov=custom_components.adguard_hub",
|
||||
"--cov-report=term-missing",
|
||||
"--cov-report=html",
|
||||
"--cov-fail-under=60",
|
||||
"--cov-fail-under=70",
|
||||
"--asyncio-mode=auto",
|
||||
"-v"
|
||||
]
|
||||
|
@@ -1,5 +1,4 @@
|
||||
"""Test AdGuard Home API client."""
|
||||
|
||||
import pytest
|
||||
from unittest.mock import AsyncMock, patch
|
||||
import aiohttp
|
||||
|
Reference in New Issue
Block a user