qlever 0.5.26__py3-none-any.whl → 0.5.28__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of qlever might be problematic. Click here for more details.

@@ -50,6 +50,7 @@ class SettingsCommand(QleverCommand):
50
50
  "spatial-join-max-num-threads",
51
51
  "syntax-test-mode",
52
52
  "throw-on-unbound-variables",
53
+ "treat-default-graph-as-named-graph",
53
54
  "use-binsearch-transitive-path",
54
55
  ]
55
56
  subparser.add_argument(
@@ -252,46 +252,74 @@ class UpdateWikidataCommand(QleverCommand):
252
252
  # operation = event_data.get("operation")
253
253
  rdf_added_data = event_data.get("rdf_added_data")
254
254
  rdf_deleted_data = event_data.get("rdf_deleted_data")
255
+ rdf_linked_shared_data = event_data.get(
256
+ "rdf_linked_shared_data"
257
+ )
258
+ rdf_unlinked_shared_data = event_data.get(
259
+ "rdf_unlinked_shared_data"
260
+ )
255
261
 
256
262
  # Process the to-be-deleted triples.
257
- if rdf_deleted_data is not None:
258
- try:
259
- rdf_deleted_data = rdf_deleted_data.get("data")
260
- graph = Graph()
261
- log.debug(f"RDF deleted data: {rdf_deleted_data}")
262
- graph.parse(data=rdf_deleted_data, format="turtle")
263
- for s, p, o in graph:
264
- triple = f"{s.n3()} {p.n3()} {o.n3()}"
265
- # NOTE: In case there was a previous `insert` of that
266
- # triple, it is safe to remove that `insert`, but not
267
- # the `delete` (in case the triple is contained in the
268
- # original data).
269
- if triple in insert_triples:
270
- insert_triples.remove(triple)
271
- delete_triples.add(triple)
272
- except Exception as e:
273
- log.error(f"Error reading `rdf_deleted_data`: {e}")
274
- return False
263
+ for rdf_to_be_deleted in (
264
+ rdf_deleted_data,
265
+ rdf_unlinked_shared_data,
266
+ ):
267
+ if rdf_to_be_deleted is not None:
268
+ try:
269
+ rdf_to_be_deleted_data = rdf_to_be_deleted.get(
270
+ "data"
271
+ )
272
+ graph = Graph()
273
+ log.debug(
274
+ f"RDF to_be_deleted data: {rdf_to_be_deleted_data}"
275
+ )
276
+ graph.parse(
277
+ data=rdf_to_be_deleted_data, format="turtle"
278
+ )
279
+ for s, p, o in graph:
280
+ triple = f"{s.n3()} {p.n3()} {o.n3()}"
281
+ # NOTE: In case there was a previous `insert` of that
282
+ # triple, it is safe to remove that `insert`, but not
283
+ # the `delete` (in case the triple is contained in the
284
+ # original data).
285
+ if triple in insert_triples:
286
+ insert_triples.remove(triple)
287
+ delete_triples.add(triple)
288
+ except Exception as e:
289
+ log.error(
290
+ f"Error reading `rdf_to_be_deleted_data`: {e}"
291
+ )
292
+ return False
275
293
 
276
294
  # Process the to-be-added triples.
277
- if rdf_added_data is not None:
278
- try:
279
- rdf_added_data = rdf_added_data.get("data")
280
- graph = Graph()
281
- log.debug("RDF added data: {rdf_added_data}")
282
- graph.parse(data=rdf_added_data, format="turtle")
283
- for s, p, o in graph:
284
- triple = f"{s.n3()} {p.n3()} {o.n3()}"
285
- # NOTE: In case there was a previous `delete` of that
286
- # triple, it is safe to remove that `delete`, but not
287
- # the `insert` (in case the triple is not contained in
288
- # the original data).
289
- if triple in delete_triples:
290
- delete_triples.remove(triple)
291
- insert_triples.add(triple)
292
- except Exception as e:
293
- log.error(f"Error reading `rdf_added_data`: {e}")
294
- return False
295
+ for rdf_to_be_added in (
296
+ rdf_added_data,
297
+ rdf_linked_shared_data,
298
+ ):
299
+ if rdf_to_be_added is not None:
300
+ try:
301
+ rdf_to_be_added_data = rdf_to_be_added.get("data")
302
+ graph = Graph()
303
+ log.debug(
304
+ "RDF to be added data: {rdf_to_be_added_data}"
305
+ )
306
+ graph.parse(
307
+ data=rdf_to_be_added_data, format="turtle"
308
+ )
309
+ for s, p, o in graph:
310
+ triple = f"{s.n3()} {p.n3()} {o.n3()}"
311
+ # NOTE: In case there was a previous `delete` of that
312
+ # triple, it is safe to remove that `delete`, but not
313
+ # the `insert` (in case the triple is not contained in
314
+ # the original data).
315
+ if triple in delete_triples:
316
+ delete_triples.remove(triple)
317
+ insert_triples.add(triple)
318
+ except Exception as e:
319
+ log.error(
320
+ f"Error reading `rdf_to_be_added_data`: {e}"
321
+ )
322
+ return False
295
323
 
296
324
  except Exception as e:
297
325
  log.error(f"Error reading data from message: {e}")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: qlever
3
- Version: 0.5.26
3
+ Version: 0.5.28
4
4
  Summary: Command-line tool for using the QLever graph database
5
5
  Author-email: Hannah Bast <bast@cs.uni-freiburg.de>
6
6
  License: Apache-2.0
@@ -37,18 +37,18 @@ qlever/commands/index.py,sha256=oudLc5f6wsWGPkfhsFXIkSH14Oh37bGqK76D5lXJmBk,1333
37
37
  qlever/commands/index_stats.py,sha256=9EBo1Oq5PGjajrvWJNafJ-Wg_d90DaO5AGq9a5plSRM,11720
38
38
  qlever/commands/log.py,sha256=vLqkgtx1udnQqoUBMWB5G9rwr-l7UKrDpyFYSMuoXWw,1987
39
39
  qlever/commands/query.py,sha256=rRiR4TFRZixLfBmITAvKVtWHn6mhOiboGG8a_Jcwc8k,4653
40
- qlever/commands/settings.py,sha256=eoxVj-Lr9SXtDCUPAPiPh-cbsC3GKGDkDTx1QntEbnA,4121
40
+ qlever/commands/settings.py,sha256=mheUn2DQFLZCEJ3-FTrbGu7M6PSVOKWl-2qTCggn_CI,4171
41
41
  qlever/commands/setup_config.py,sha256=wEy1LAunpOnqrUCbazMpt1u9HJCKgXJEMxF3zjh0jb0,3344
42
42
  qlever/commands/start.py,sha256=g_5-BUiSYJjL10ae91jMA5SgI0zk4O4gPMN_BOuERmc,10854
43
43
  qlever/commands/status.py,sha256=TtnBqcdkF3zTDKft07zpVcIX7kFu7d_nOy9b6Ohh9vQ,1650
44
44
  qlever/commands/stop.py,sha256=5BNKArOzoJ8kYiTVAmtN81w7nQ42fkxISgsxL-qJpO0,3463
45
45
  qlever/commands/system_info.py,sha256=I84EKgMO5J8pvsTDhkVKHzsRLtPajNg9KTQN5kWjqLU,4660
46
46
  qlever/commands/ui.py,sha256=Kjv5FKN0pjMCpJS6otbrczs364x24FAnsJjtnc98mJQ,9811
47
- qlever/commands/update_wikidata.py,sha256=1IkYqrgbIV2tJliEORhzv1rMjjipnxe-5FTLrKes1FA,23312
47
+ qlever/commands/update_wikidata.py,sha256=MQWNTe7KtadlTAsxCsntKYWZLSoX6H8l6WI4s6UfFqY,24484
48
48
  qlever/commands/warmup.py,sha256=kJHzS7HJo8pD2CphJuaXDj_CYP02YDo2DVM-pun3A80,1029
49
- qlever-0.5.26.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
50
- qlever-0.5.26.dist-info/METADATA,sha256=GS_dGYncRUVfYJvuV67nBTaMwvb8jQhf25j9nyg76kU,5151
51
- qlever-0.5.26.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
52
- qlever-0.5.26.dist-info/entry_points.txt,sha256=U_1U6SFIEZ-AnNlvk2nzcL0e4jnjEpuSbxYZ_E0XpEg,51
53
- qlever-0.5.26.dist-info/top_level.txt,sha256=kd3zsYqiFd0--Czh5XTVkfEq6XR-XgRFW35X0v0GT-c,7
54
- qlever-0.5.26.dist-info/RECORD,,
49
+ qlever-0.5.28.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
50
+ qlever-0.5.28.dist-info/METADATA,sha256=HU42qXyeDo3r4c9xi1ekHzTXNLyT84LEf0-Oy1l09z4,5151
51
+ qlever-0.5.28.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
52
+ qlever-0.5.28.dist-info/entry_points.txt,sha256=U_1U6SFIEZ-AnNlvk2nzcL0e4jnjEpuSbxYZ_E0XpEg,51
53
+ qlever-0.5.28.dist-info/top_level.txt,sha256=kd3zsYqiFd0--Czh5XTVkfEq6XR-XgRFW35X0v0GT-c,7
54
+ qlever-0.5.28.dist-info/RECORD,,