File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -138,7 +138,11 @@ def query(the_query):
138
138
sparqlQuery .setQuery (the_query )
139
139
if LOG_SPARQL_QUERIES :
140
140
log ("Execute query: \n " + the_query )
141
- return sparqlQuery .query ().convert ()
141
+ try :
142
+ return sparqlQuery .query ().convert ()
143
+ except Exception as e :
144
+ log ("Failed Query: \n " + the_query )
145
+ raise e
142
146
143
147
144
148
def update (the_query ):
@@ -153,7 +157,11 @@ def update(the_query):
153
157
if sparqlUpdate .isSparqlUpdateRequest ():
154
158
if LOG_SPARQL_UPDATES :
155
159
log ("Execute query: \n " + the_query )
156
- sparqlUpdate .query ()
160
+ try :
161
+ sparqlUpdate .query ()
162
+ except Exception as e :
163
+ log ("Failed Query: \n " + the_query )
164
+ raise e
157
165
158
166
159
167
def update_modified (subject , modified = datetime .datetime .now ()):
You can’t perform that action at this time.
0 commit comments