Skip to content

script stops working #123

@sega-gremlen

Description

@sega-gremlen

Hello it's working until python 3.11 update (only in my opinion) on my manjaro os

command that i use:
vcsi input.mp4 -g 3x5 --output otput.jpg

Traceback (most recent call last):
  File "/home/fila/.local/bin/vcsi", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/usr/lib/python3.11/site-packages/vcsi/__init__.py", line 3, in main
    vcsi.vcsi.main()
  File "/usr/lib/python3.11/site-packages/vcsi/vcsi.py", line 1331, in main
    process_file(filename, args)
  File "/usr/lib/python3.11/site-packages/vcsi/vcsi.py", line 1389, in process_file
    image = compose_contact_sheet(media_info, selected_frames, args)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/vcsi/vcsi.py", line 785, in compose_contact_sheet
    header_lines = prepare_metadata_text_lines(
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/vcsi/vcsi.py", line 709, in prepare_metadata_text_lines
    max_metadata_line_length = max_line_length(
                               ^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/vcsi/vcsi.py", line 678, in max_line_length
    text_width = 0 if len(text_chunk) == 0 else metadata_font.getsize(text_chunk)[0]
                                                ^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'FreeTypeFont' object has no attribute 'getsize'

It happens in the end of composing
hashtag after text_width = 0 helps

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions