From 875d449f0672458a3a222b5b52f12ceed5e0f907 Mon Sep 17 00:00:00 2001 From: DerekFurstPitt Date: Tue, 27 Feb 2024 14:41:16 -0500 Subject: [PATCH] changed `id` to `id.strip()` in get_hubmap_ids and entity_instanceof --- src/app.py | 2 +- src/schema/schema_manager.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app.py b/src/app.py index da426817..75a75367 100644 --- a/src/app.py +++ b/src/app.py @@ -4772,7 +4772,7 @@ def query_target_entity(id, user_token): try: # Get cached ids if exist otherwise retrieve from UUID-API - hubmap_ids = schema_manager.get_hubmap_ids(id) + hubmap_ids = schema_manager.get_hubmap_ids(id.strip()) # Get the target uuid if all good uuid = hubmap_ids['hm_uuid'] diff --git a/src/schema/schema_manager.py b/src/schema/schema_manager.py index 6fc0e7d5..8c6318e1 100644 --- a/src/schema/schema_manager.py +++ b/src/schema/schema_manager.py @@ -243,7 +243,7 @@ def entity_instanceof(entity_uuid: str, entity_class: str) -> bool: :return: True or False """ entity_type: str =\ - schema_neo4j_queries.get_entity_type(get_neo4j_driver_instance(), entity_uuid) + schema_neo4j_queries.get_entity_type(get_neo4j_driver_instance(), entity_uuid.strip()) return entity_type_instanceof(entity_type, entity_class)