jeanslack / Videomass

Videomass is a free, open source and cross-platform GUI for FFmpeg and yt-dlp
https://jeanslack.github.io/Videomass/
GNU General Public License v3.0
1.06k stars 49 forks source link

fix ValueError passing N/A string #261

Closed jeanslack closed 7 months ago

jeanslack commented 7 months ago

This PR fixes:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/wx/core.py", line 3427, in <lambda>
    lambda event: event.callable(*event.args, **event.kw) )
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/pubsub/core/publisher.py", line 216, in sendMessage
    topicObj.publish(**msgData)
  File "/usr/lib/python3/dist-packages/pubsub/core/topicobj.py", line 452, in publish
    self.__sendMessage(msgData, topicObj, msgDataSubset)
  File "/usr/lib/python3/dist-packages/pubsub/core/topicobj.py", line 482, in __sendMessage
    listener(data, self, allData)
  File "/usr/lib/python3/dist-packages/pubsub/core/listener.py", line 237, in __call__
    cb(**kwargs)
  File "/home/u0/Videomass/videomass/vdms_panels/long_processing_task.py", line 244, in update_display
    msec = get_milliseconds(pos)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/u0/Videomass/videomass/vdms_utils/utils.py", line 249, in get_milliseconds
    seconds = float(seconds)
              ^^^^^^^^^^^^^^
ValueError: could not convert string to float: 'N/A'