From 198221651fac092b0a1fab066b8a20561aca25aa Mon Sep 17 00:00:00 2001 From: Kai Labusch Date: Tue, 12 Nov 2024 17:01:34 +0100 Subject: [PATCH] fix command line output --- qurator/tsvtools/cli.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/qurator/tsvtools/cli.py b/qurator/tsvtools/cli.py index 252ee00..e14a33f 100644 --- a/qurator/tsvtools/cli.py +++ b/qurator/tsvtools/cli.py @@ -307,6 +307,10 @@ def tsv2tsv(tsv_in_file, tsv_out_file, ner_rest_endpoint, noproxy, else: tsv_tmp, _ = ner(tsv, ner_rest_endpoint, keep_tokenization=keep_tokenization) + if tsv_out_file is None: + print("\n") + return + print("\n==>") print("Output file: {}".format(tsv_out_file)) @@ -356,10 +360,6 @@ def tsv2tsv(tsv_in_file, tsv_out_file, ner_rest_endpoint, noproxy, word_pos += 1 - if tsv_out_file is None: - print("\n") - return - write_tsv(tsv_out, urls, contexts, tsv_out_file) print("\n")