Coverage for heritrace/utils/virtuoso_utils.py: 100%
7 statements
« prev ^ index » next coverage.py v7.6.12, created at 2025-04-18 11:10 +0000
« prev ^ index » next coverage.py v7.6.12, created at 2025-04-18 11:10 +0000
1from flask import current_app
4VIRTUOSO_EXCLUDED_GRAPHS = [
5 "http://localhost:8890/DAV/",
6 "http://www.openlinksw.com/schemas/virtrdf#",
7 "http://www.w3.org/2002/07/owl#",
8 "http://www.w3.org/ns/ldp#",
9 "urn:activitystreams-owl:map",
10 "urn:core:services:sparql",
11]
14def is_virtuoso(app=None):
15 """
16 Check if the triplestore is Virtuoso.
18 Args:
19 app: Flask application object (optional)
21 Returns:
22 bool: True if triplestore is Virtuoso, False otherwise
23 """
24 if app is None:
25 from flask import current_app
27 app = current_app
28 return app.config["DATASET_DB_TRIPLESTORE"].lower() == "virtuoso"