From 9d5422bcb2b6bde1273ba0d187eca32998e60a18 Mon Sep 17 00:00:00 2001 From: Nikos Date: Fri, 7 Apr 2023 16:10:57 +0300 Subject: [PATCH] Fix tests --- src/charm.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/charm.py b/src/charm.py index 7f7723a5..50640299 100755 --- a/src/charm.py +++ b/src/charm.py @@ -10,7 +10,7 @@ from functools import cached_property from os.path import join from pathlib import Path -from typing import Any, List, Optional +from typing import TYPE_CHECKING, Any, List, Optional from charms.data_platform_libs.v0.data_interfaces import ( DatabaseCreatedEvent, @@ -36,7 +36,12 @@ from ops.charm import CharmBase, ConfigChangedEvent, HookEvent, PebbleReadyEvent, RelationEvent from ops.main import main from ops.model import ActiveStatus, BlockedStatus, MaintenanceStatus, ModelError, WaitingStatus -from ops.pebble import ExecError, Layer, LayerDict +from ops.pebble import ExecError, Layer + + +if TYPE_CHECKING: + from ops.pebble import LayerDict + logger = logging.getLogger(__name__) KRATOS_ADMIN_PORT = 4434