From d497749c780ad3d6ce73eee47330d37baf6f2cfa Mon Sep 17 00:00:00 2001 From: Ozbolt Menegatti Date: Wed, 21 Aug 2019 11:08:08 +0200 Subject: [PATCH] better database commiting --- src/wani.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wani.py b/src/wani.py index 3ba75a5..364ccc4 100644 --- a/src/wani.py +++ b/src/wani.py @@ -47,6 +47,7 @@ def main(args): matches = match_file(words, structures) match_store.add_matches(matches) word_stats.add_words(words) + database.commit() # force a bit of garbage collection del words @@ -55,7 +56,6 @@ def main(args): # if no output files, just exit if all([x == None for x in [args.out, args.out_no_stat, args.all, args.stats]]): - database.commit() return # get word renders for lemma/msd