mdify-cli 2.9.5__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.5
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.5"
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
  # =============================================================================
@@ -982,6 +982,7 @@ def main() -> int:
982
982
  )
983
983
  elapsed = time.time() - start_time
984
984
 
985
+ # Stop spinner before any output
985
986
  if not args.quiet:
986
987
  spinner.stop()
987
988
 
@@ -1004,12 +1005,27 @@ def main() -> int:
1004
1005
  except Exception as e:
1005
1006
  elapsed = time.time() - start_time
1006
1007
  failed_count += 1
1008
+ # Stop spinner before printing error
1007
1009
  if not args.quiet:
1008
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:
1009
1025
  print(
1010
1026
  f"{progress} {input_file.name} ✗ ({format_duration(elapsed)})"
1011
1027
  )
1012
- print(f" Error: {str(e)}", file=sys.stderr)
1028
+ print(f" Error: {error_msg}", file=sys.stderr)
1013
1029
 
1014
1030
  total_elapsed = time.time() - conversion_start
1015
1031
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mdify-cli
3
- Version: 2.9.5
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.5"
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