From d168edfd77119fb9501cf66aaa0f5f42a687f248 Mon Sep 17 00:00:00 2001 From: michalbubula <149780022+michalbubula@users.noreply.github.com> Date: Thu, 19 Sep 2024 15:20:37 +0200 Subject: [PATCH] Update cli.py to block other processing in the case of extract_image_only --- src/eynollah/cli.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/eynollah/cli.py b/src/eynollah/cli.py index 82505ed..564b8b0 100644 --- a/src/eynollah/cli.py +++ b/src/eynollah/cli.py @@ -182,8 +182,8 @@ def main( if textline_light and not light_version: print('Error: You used -tll to enable light textline detection but -light is not enabled') sys.exit(1) - if extract_only_images and (allow_enhancement or allow_scaling or light_version) : - print('Error: You used -eoi which can not be enabled alongside light_version -light or allow_scaling -as or allow_enhancement -ae') + if extract_only_images and (allow_enhancement or allow_scaling or light_version or curved_line or textline_light or full_layout or tables or right2left or headers_off) : + print('Error: You used -eoi which can not be enabled alongside light_version -light or allow_scaling -as or allow_enhancement -ae or curved_line -cl or textline_light -tll or full_layout -fl or tables -tab or right2left -r2l or headers_off -ho') sys.exit(1) eynollah = Eynollah( image_filename=image,