From 3dfee10d7ffc647d1d7fe56f689e6d0d88f6788d Mon Sep 17 00:00:00 2001 From: kovalch Date: Thu, 11 Apr 2024 12:44:31 +0200 Subject: [PATCH 1/2] fix: Temporary use only dataset graph from platform We need to communicate to the publisher first before using the graph from the harvester source, since there were many properties added to the shacl graph --- ckan_pkg_checker/checkers/shacl_checker.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ckan_pkg_checker/checkers/shacl_checker.py b/ckan_pkg_checker/checkers/shacl_checker.py index 1d79475..d5ebdf5 100644 --- a/ckan_pkg_checker/checkers/shacl_checker.py +++ b/ckan_pkg_checker/checkers/shacl_checker.py @@ -92,13 +92,13 @@ def check_package(self, pkg): """Check one data package""" pkg_type = pkg.get("pkg_type", utils.DCAT) dataset_graph = None - if pkg.get("source_url"): - dataset_graph = rdf_utils.get_dataset_graph_from_source( - pkg["source_url"], pkg["identifier"] - ) - utils.log_and_echo_msg( - f"--> rdf graph for Dataset{pkg.get('name')} taken from harvest source" - ) + # if pkg.get("source_url"): + # dataset_graph = rdf_utils.get_dataset_graph_from_source( + # pkg["source_url"], pkg["identifier"] + # ) + # utils.log_and_echo_msg( + # f"--> rdf graph for Dataset{pkg.get('name')} taken from harvest source" + # ) if not dataset_graph: pkg_dcat_serilization_url = utils.get_pkg_dcat_serialization_url( self.siteurl, pkg["name"] From d12b1dfee508e8e257f4dba4e354e13f2bcbeb29 Mon Sep 17 00:00:00 2001 From: kovalch Date: Thu, 11 Apr 2024 13:35:54 +0200 Subject: [PATCH 2/2] fix: Add comment todos comment --- ckan_pkg_checker/checkers/shacl_checker.py | 1 + 1 file changed, 1 insertion(+) diff --git a/ckan_pkg_checker/checkers/shacl_checker.py b/ckan_pkg_checker/checkers/shacl_checker.py index d5ebdf5..ce648cc 100644 --- a/ckan_pkg_checker/checkers/shacl_checker.py +++ b/ckan_pkg_checker/checkers/shacl_checker.py @@ -92,6 +92,7 @@ def check_package(self, pkg): """Check one data package""" pkg_type = pkg.get("pkg_type", utils.DCAT) dataset_graph = None + # todo: Reenable checking harvest source graph once changes have been communicated to publishers # if pkg.get("source_url"): # dataset_graph = rdf_utils.get_dataset_graph_from_source( # pkg["source_url"], pkg["identifier"]