From: Daniel Arndt Date: Fri, 21 Apr 2023 12:32:04 +0000 (-0300) Subject: Add type hint for NsDbActivity X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=refs%2Fchanges%2F56%2F13256%2F1;p=osm%2FLCM.git Add type hint for NsDbActivity Change-Id: I1c9bb675d7eab2706afa23af75557896caa73396 Signed-off-by: Daniel Arndt --- diff --git a/osm_lcm/temporal/ns_activities.py b/osm_lcm/temporal/ns_activities.py index 2e08f91..c48628a 100644 --- a/osm_lcm/temporal/ns_activities.py +++ b/osm_lcm/temporal/ns_activities.py @@ -28,6 +28,8 @@ from osm_common.temporal_constants import ( ) from temporalio import activity +from osm_lcm.data_utils.database.database import Database + class NsOperations: def __init__(self, db): @@ -50,8 +52,8 @@ class NsDbActivity: db (object): Data Access Object """ - def __init__(self, db): - self.db = db + def __init__(self, db: Database): + self.db: Database = db self.logger = logging.getLogger(f"lcm.act.{self.__class__.__name__}") @activity.defn(name=ACTIVITY_UPDATE_NS_STATE)