mdify-cli 2.9.4__tar.gz → 2.10.0__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mdify-cli
3
- Version: 2.9.4
3
+ Version: 2.10.0
4
4
  Summary: Convert PDFs and document images into structured Markdown for LLM workflows
5
5
  Author: tiroq
6
6
  License-Expression: MIT
@@ -1,3 +1,3 @@
1
1
  """mdify - Convert documents to Markdown via Docling container."""
2
2
 
3
- __version__ = "2.9.4"
3
+ __version__ = "2.10.0"
@@ -521,8 +521,8 @@ class Spinner:
521
521
  self.running = False
522
522
  if self.thread:
523
523
  self.thread.join(timeout=0.5)
524
- # Clear the spinner line
525
- print(f"\r{' ' * 80}\r", end="", flush=True)
524
+ # Clear the spinner line with enough spaces to cover the longest possible line
525
+ print(f"\r{' ' * 120}\r", end="", flush=True)
526
526
 
527
527
 
528
528
  # =============================================================================
@@ -918,6 +918,8 @@ def main() -> int:
918
918
 
919
919
  if not args.quiet:
920
920
  print(f"Found {total_files} file(s) to convert ({format_size(total_size)})")
921
+ print(f"Source: {input_path.resolve()}")
922
+ print(f"Output: {output_dir.resolve()}")
921
923
  print(f"Using runtime: {runtime}")
922
924
  print(f"Using image: {image}")
923
925
  print()
@@ -980,6 +982,7 @@ def main() -> int:
980
982
  )
981
983
  elapsed = time.time() - start_time
982
984
 
985
+ # Stop spinner before any output
983
986
  if not args.quiet:
984
987
  spinner.stop()
985
988
 
@@ -1002,12 +1005,27 @@ def main() -> int:
1002
1005
  except Exception as e:
1003
1006
  elapsed = time.time() - start_time
1004
1007
  failed_count += 1
1008
+ # Stop spinner before printing error
1005
1009
  if not args.quiet:
1006
1010
  spinner.stop()
1011
+
1012
+ # Check if container is still healthy
1013
+ error_msg = str(e)
1014
+ if "Connection refused" in error_msg or "Connection aborted" in error_msg or "RemoteDisconnected" in error_msg:
1015
+ if not container.is_ready():
1016
+ if not args.quiet:
1017
+ print(
1018
+ f"{progress} {input_file.name} ✗ ({format_duration(elapsed)})"
1019
+ )
1020
+ print(f" Error: Container crashed (file may be too complex or large)", file=sys.stderr)
1021
+ print(f" Stopping remaining conversions", file=sys.stderr)
1022
+ break
1023
+
1024
+ if not args.quiet:
1007
1025
  print(
1008
1026
  f"{progress} {input_file.name} ✗ ({format_duration(elapsed)})"
1009
1027
  )
1010
- print(f" Error: {str(e)}", file=sys.stderr)
1028
+ print(f" Error: {error_msg}", file=sys.stderr)
1011
1029
 
1012
1030
  total_elapsed = time.time() - conversion_start
1013
1031
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mdify-cli
3
- Version: 2.9.4
3
+ Version: 2.10.0
4
4
  Summary: Convert PDFs and document images into structured Markdown for LLM workflows
5
5
  Author: tiroq
6
6
  License-Expression: MIT
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "mdify-cli"
3
- version = "2.9.4"
3
+ version = "2.10.0"
4
4
  description = "Convert PDFs and document images into structured Markdown for LLM workflows"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.8"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes