From 0bb67e65ad6bc644526074d63902459be955e9aa Mon Sep 17 00:00:00 2001 From: Tyler Gu Date: Fri, 6 Sep 2024 18:06:04 -0500 Subject: [PATCH] Logging Signed-off-by: Tyler Gu --- acto/schema/array.py | 2 ++ acto/schema/object.py | 2 ++ acto/schema/string.py | 2 ++ 3 files changed, 6 insertions(+) diff --git a/acto/schema/array.py b/acto/schema/array.py index 87f259056..c2f74c7e2 100644 --- a/acto/schema/array.py +++ b/acto/schema/array.py @@ -1,3 +1,4 @@ +import logging import random from typing import List, Tuple @@ -101,6 +102,7 @@ def to_tree(self) -> TreeNode: return node def load_examples(self, example: list): + logging.debug(f"Loading example {example} into {self}") self.examples.append(example) for item in example: self.item_schema.load_examples(item) diff --git a/acto/schema/object.py b/acto/schema/object.py index 5603db4f3..05402b537 100644 --- a/acto/schema/object.py +++ b/acto/schema/object.py @@ -1,3 +1,4 @@ +import logging import random from typing import List, Tuple @@ -129,6 +130,7 @@ def to_tree(self) -> TreeNode: return node def load_examples(self, example: dict): + logging.debug(f"Loading example {example} into {self}") self.examples.append(example) for key, value in example.items(): if key in self.properties: diff --git a/acto/schema/string.py b/acto/schema/string.py index 2d8afd179..3cc96cfa8 100644 --- a/acto/schema/string.py +++ b/acto/schema/string.py @@ -1,3 +1,4 @@ +import logging import random from typing import List, Optional, Tuple @@ -47,6 +48,7 @@ def to_tree(self) -> TreeNode: return TreeNode(self.path) def load_examples(self, example: str): + logging.debug(f"Loading example {example} into {self}") self.examples.append(example) def set_default(self, instance):