Skip to content

Commit

Permalink
More path fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
caufieldjh committed May 29, 2024
1 parent cfb6837 commit 0da2de7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ontogpt/io/template_loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,13 @@ def get_template_details(template: TEMPLATE_NAME) -> ClassDefinition:

else:
logger.info(f"Loading schema for {template}")
path_to_template = get_template_path(module_name)
sv = SchemaView(path_to_template)
if "." in template:
module_name, class_name = template.split(".", 1)
else:
module_name = template
class_name = None
path_to_template = get_template_path(module_name)
sv = SchemaView(path_to_template)
mod = importlib.import_module(f"ontogpt.templates.{module_name}")

if class_name is None:
Expand Down

0 comments on commit 0da2de7

Please sign in to comment.