From 5a3c56378b659f634b7a45027ebd307ecedec1e1 Mon Sep 17 00:00:00 2001 From: "Francesca L. Bleken" Date: Thu, 4 Aug 2022 12:53:19 +0200 Subject: [PATCH 1/2] Strip leading and trailing white spaces in path to imported ontologies in excelparser --- ontopy/excelparser.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ontopy/excelparser.py b/ontopy/excelparser.py index 4e6f85eae..87d721453 100755 --- a/ontopy/excelparser.py +++ b/ontopy/excelparser.py @@ -107,7 +107,7 @@ def create_ontology_from_excel( # pylint: disable=too-many-arguments except ValueError: pass else: - imports.extend(imports_frame["Imported ontologies"].to_list()) + imports.extend(imports_frame["Imported ontologies"].str.strip().to_list()) # Read datafile TODO: Some magic to identify the header row conceptdata = pd.read_excel( From a865a749be9ea67e05876f48f231ec41de475454 Mon Sep 17 00:00:00 2001 From: "Francesca L. Bleken" Date: Thu, 4 Aug 2022 12:57:13 +0200 Subject: [PATCH 2/2] Added comment --- ontopy/excelparser.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ontopy/excelparser.py b/ontopy/excelparser.py index 87d721453..913063d15 100755 --- a/ontopy/excelparser.py +++ b/ontopy/excelparser.py @@ -107,7 +107,10 @@ def create_ontology_from_excel( # pylint: disable=too-many-arguments except ValueError: pass else: - imports.extend(imports_frame["Imported ontologies"].str.strip().to_list()) + # Strip leading and trailing white spaces in path + imports.extend( + imports_frame["Imported ontologies"].str.strip().to_list() + ) # Read datafile TODO: Some magic to identify the header row conceptdata = pd.read_excel(