spoti-dl icon indicating copy to clipboard operation
spoti-dl copied to clipboard

Unable to write metadata for song!

Open nethakha opened this issue 1 year ago • 11 comments

When I try to download a particular song, I get "Unable to write metadata for song!

How can I resolve this issue?

nethakha avatar Feb 09 '24 13:02 nethakha

Hi, can you please share the log file with name spotidl.log found at home directory?

dhruv-ahuja avatar Feb 19 '24 04:02 dhruv-ahuja

09/02/2024 10:37:14 PM | WARNING: Couldn't read cache at: .cache 09/02/2024 10:37:18 PM | WARNING: Couldn't write token to cache at: .cache 09/02/2024 10:37:30 PM | ERROR: error 指定されたパスが見つかりません。 (os error 3) opening song file "C:\Users\tokut/dl\再生\→真逆様←.opus" for writing metadata 09/02/2024 10:40:01 PM | WARNING: Couldn't read cache at: .cache 09/02/2024 10:40:05 PM | WARNING: Couldn't write token to cache at: .cache 09/02/2024 10:40:08 PM | ERROR: error 指定されたパスが見つかりません。 (os error 3) opening song file "C:\Users\tokut/dl\再生\5 →真逆様←.opus" for writing metadata

nethakha avatar Feb 20 '24 00:02 nethakha

Thanks for sharing this, can you please try running the app as admin? For windows, that would require opening the terminal/command line as admin and then running spoti-dl.

dhruv-ahuja avatar Feb 20 '24 10:02 dhruv-ahuja

Thank you, I was able to download the desired sound source! However, when I tried to download another sound source, the problem occurred again. Here is the contents of the log file.

21/02/2024 09:32:20 PM | WARNING: Couldn't read cache at: .cache 21/02/2024 09:32:23 PM | WARNING: Couldn't write token to cache at: .cache 21/02/2024 09:32:26 PM | ERROR: error 指定されたパスが見つかりません。 (os error 3) opening song file "C:\Users\tokut/dl\futuring Prod.Morning Lemon\futuring ProdMorning Lemon.opus" for writing metadata

nethakha avatar Feb 21 '24 12:02 nethakha

Okay, I see. I will look into this. Thanks for reporting this issue.

dhruv-ahuja avatar Feb 21 '24 17:02 dhruv-ahuja

@nethakha Hey, sorry for the late update -- was having issues with my systems and hence was unable to build the Windows version of the app for a long time. Can you please update the app to version 2.1.2 -- it should fix your issue now. python3 -m pip install --upgrade spoti-dl==2.1.2 or pip install --upgrade spoti-dl==2.1.2 is what you need to do, might need adjustments since python setup can vary from system to system.

dhruv-ahuja avatar Jun 11 '24 20:06 dhruv-ahuja

Thanks for the update. I tried it but it did not work.

Below is the log.

13/06/2024 05:06:28 PM | WARNING: Couldn't read cache at: .cache
13/06/2024 05:06:30 PM | WARNING: Couldn't write token to cache at: .cache
13/06/2024 05:06:31 PM | ERROR: error 指定されたファイルが見つかりません。 (os error 2) opening song file "C:\\Users\\tokut\\dl\\futuring ProdMorning Lemon.opus" for writing metadata

I don't know if this is related, but it appears that the ". seems to have been removed from the file name. The name of the song is "futuring Prod.Morning Lemon", but in the log it is "futuring ProdMorning Lemon".

I hope the problem will be resolved.

nethakha avatar Jun 13 '24 08:06 nethakha

Oh right, that could be the case. I'll look into this when time permits, and get back to you. Could you please share the song link(s) that caused you the trouble?

dhruv-ahuja avatar Jun 13 '24 17:06 dhruv-ahuja

This song. https://open.spotify.com/intl-ja/track/5amIghCsQS7andDFxrvNi3?si=2914aaee57ba4b4d

nethakha avatar Jun 14 '24 17:06 nethakha

Could you share what command are you using exactly, and the path to the dl folder (running just cd in your terminal will show the path)? I tried downloading the same song on my windows machine and had no issues there. There might be some permission issues, can you try downloading the song in some other drive other than the c: drive?

The . (and other characters) in the song name is replaced to avoid any issues when creating files, so that's not the issue here.

dhruv-ahuja avatar Jun 17 '24 06:06 dhruv-ahuja

I tried the following three commands.

spoti-dl spotify:track:5amIghCsQS7andDFxrvNi3
spoti-dl https://open.spotify.com/intl-ja/track/5amIghCsQS7andDFxrvNi3
spoti-dl https://open.spotify.com/intl-ja/album/6tAqWourYOmhQikvkEzwk3

The dl folder is located directly under the user directory.

C:\Users\tokut\dl

I tried executing it by specifying a download destination to a drive other than the C drive, but the result did not change.

nethakha avatar Jun 17 '24 06:06 nethakha