pdfplumber icon indicating copy to clipboard operation
pdfplumber copied to clipboard

page.crop causes the program to freeze

Open KingDracula opened this issue 10 months ago • 1 comments

  • pdfplumber version: [0.11.4]
  • Python version: [3.11.9]
  • OS: [win11] when i use the ThreadPoolExecutor simultaneously batch parsing multiple files Can cause Python processes to unexpectedly freeze After debugging, it was found that it may be caused by this code

image_bbox =[image['x0'],image['top'],image['x1'],image['bottom']] cropped= page.crop(image_bbox) image_obj=cropped.to_image(resolution=500) cropped.close()

Read a single file is fine

How to fix it Thanks

KingDracula avatar Mar 11 '25 03:03 KingDracula

Thank you for flagging. Could you provide a PDF, as well as a reproducible script, that replicates this issue?

jsvine avatar Apr 21 '25 11:04 jsvine