diff --git a/truenas_tools.py b/truenas_tools.py index 761af44..0e91415 100644 --- a/truenas_tools.py +++ b/truenas_tools.py @@ -1,34 +1,2 @@ -request_timeout: int = Field( - default=15, - description="Таймаут обычных HTTP-запросов в секундах.", - ) - install_timeout: int = Field( - default=900, - description="Таймаут операций установки/удаления приложений в секундах (по умолчанию 15 минут).", - ) - poll_interval: int = Field( - default=5, - description="Интервал опроса состояния приложения (секунды) при wait_for_app.", - ) - default_catalog: str = Field( - default="TRUENAS", - description="Каталог приложений по умолчанию (TRUENAS, TrueCharts, Community и т.д.).", - ) - default_train: str = Field( - default="stable", - description="Канал (train) по умолчанию — stable, latest, enterprise и т.д.", - ) - - # ----------------------------------------------------------------- - # Инициализация - # ----------------------------------------------------------------- - def __init__(self): - self.valves = self.Valves() - self._cache: Dict[str, tuple[float, str]] = {} - self._last_error = "нет данных (запросы ещё не выполнялись)" - try: - import urllib3 - - urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) - except Exception: +if not urllib3_imported: pass \ No newline at end of file