amietn / vcsi

Create video contact sheets, thumbnails
MIT License
491 stars 57 forks source link

Create new folder. If the -o, OUTPUT folder does not exist #125

Open orithecapper opened 1 year ago

orithecapper commented 1 year ago

Traceback (most recent call last): File "/home/ori/.pyenv/versions/3.11.5/lib/python3.11/site-packages/PIL/Image.py", line 2390, in save format = EXTENSION[ext]


KeyError: ''

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/ori/.pyenv/versions/3.11.5/bin/vcsi", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/home/ori/.pyenv/versions/3.11.5/lib/python3.11/site-packages/vcsi/vcsi.py", line 1647, in main
    process_file_or_ignore(filename, args)
  File "/home/ori/.pyenv/versions/3.11.5/lib/python3.11/site-packages/vcsi/vcsi.py", line 1621, in process_file_or_ignore
    process_file(filepath, args)
  File "/home/ori/.pyenv/versions/3.11.5/lib/python3.11/site-packages/vcsi/vcsi.py", line 1780, in process_file
    is_save_successful = save_image(args, image, media_info, output_path)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ori/.pyenv/versions/3.11.5/lib/python3.11/site-packages/vcsi/vcsi.py", line 1140, in save_image
    image.save(output_path, optimize=True, quality=args.image_quality)
  File "/home/ori/.pyenv/versions/3.11.5/lib/python3.11/site-packages/PIL/Image.py", line 2393, in save
    raise ValueError(msg) from e
ValueError: unknown file extension: 
minicoz commented 1 month ago

I opened up a PR for this here https://github.com/amietn/vcsi/pull/134