diff options
author | Matthias Baumgartner <dev@igsor.net> | 2022-12-18 13:37:02 +0100 |
---|---|---|
committer | Matthias Baumgartner <dev@igsor.net> | 2022-12-18 13:37:02 +0100 |
commit | 5850ff2bcb1052883cf301590126609b0657fbc9 (patch) | |
tree | 9fb9bfa9e4c150b1a52f58d2c972445fc85b1cdf /bsie/apps | |
parent | 22896f662ed49dd9fa283af2b3dad9e4ec6dd340 (diff) | |
download | bsie-5850ff2bcb1052883cf301590126609b0657fbc9.tar.gz bsie-5850ff2bcb1052883cf301590126609b0657fbc9.tar.bz2 bsie-5850ff2bcb1052883cf301590126609b0657fbc9.zip |
cosmetic changes
Diffstat (limited to 'bsie/apps')
-rw-r--r-- | bsie/apps/index.py | 28 |
1 files changed, 11 insertions, 17 deletions
diff --git a/bsie/apps/index.py b/bsie/apps/index.py index e37684b..1dbfdd8 100644 --- a/bsie/apps/index.py +++ b/bsie/apps/index.py @@ -98,23 +98,17 @@ def main(argv): walk(print) return None - else: - # initialize bsfs - # NOTE: With presistent storages, the schema migration will be a seaparte operation. - # Here, we'd simply examine the schema and potentially discard more predicates. - store = bsfs.Open({ - 'Graph': { - 'user': args.user, - 'backend': { - 'SparqlStore': {}}, - }}) - store.migrate(bsie.schema) - # process files - def handle(node, pred, value): - store.node(node.node_type, node.uri).set(pred.uri, value) - walk(handle) - # return store - return store + # initialize bsfs + # NOTE: With presistent storages, the schema migration will be a seaparte operation. + # Here, we'd simply examine the schema and potentially discard more predicates. + store = bsfs.Open(bsfs.init_sparql_store(args.user)) + store.migrate(bsie.schema) + # process files + def handle(node, pred, value): + store.node(node.node_type, node.uri).set(pred.uri, value) + walk(handle) + # return store + return store |