Seji64 / spoonie

Sync Spotify playlist to a Creative Tonie
MIT License
5 stars 0 forks source link

FileNotFoundError #1

Closed heilmoa closed 5 months ago

heilmoa commented 6 months ago

Thank you very very much for your work. It was the first repository for Spotify to Tonie Sync i got running and had no further problems.

Small issue with file names that have special characters in the name.

Probably because of the artist name with the dot in the name.

2024-04-01 05:30:07,900 | [Errno 2] No such file or directory: '/app/data/download/Josh. - Cordula Grün.mp3'
Traceback (most recent call last):
  File "/app/spoonie.py", line 449, in main
    tonie_api.upload_file_to_tonie(creative_tonie,value,key)
  File "/usr/local/lib/python3.12/site-packages/tonie_api/api.py", line 129, in upload_file_to_tonie
    with file.open("rb") as _fs:
         ^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/pathlib.py", line 1013, in open
    return io.open(self, mode, buffering, encoding, errors, newline)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '/app/data/download/Josh. - Cordula Grün.mp3'
Seji64 commented 5 months ago

Hi, today i had some time to look at the code. I cannot reproduce the issue (tested on windows and linux ). Maybe i fixed it 'accidentally' while fixing the other things. can you test it again with the latest version?

heilmoa commented 5 months ago

I have tested it now, you are right. Now it works!