glomatico / gamdl

A Python CLI app for downloading Apple Music songs/music videos/posts.
587 stars 76 forks source link

Problems with incomplete file names after downloading #83

Closed bdim404 closed 4 months ago

bdim404 commented 4 months ago

Hello, I've been working on secondary development through your project recently, and I've noticed that m4a files after downloading through gamdl are truncated if the music name is too long.

The music I tested is: https://music.apple.com/us/album/1-800-273-8255-feat-alessia-cara-khalid/1456232697?i=1456232983 After downloading it is stored as . /Apple Music/Logic/Everybody (Deluxe Edition)/10 1-800-273-8255 (feat. Alessia Car.m4a

So when I get that song title from Apple Music, it doesn't look up from the file I've already downloaded, because its correct song title is: 1-800-273-8255 (feat. Alessia Cara & Khalid).m4a

# your file name
file_path = "./Apple Music/Logic/Everybody (Deluxe Edition)/10 1-800-273-8255 (feat. Alessia Car.m4a"

# the right file name
file_path = "/Apple Music/Logic/Everybody (Deluxe Edition)/1-800-273-8255 (feat. Alessia Cara & Khalid).m4a"
fernvenue commented 4 months ago

Can be reproduced:

image

Seems both the folder name and file name are truncated.

glomatico commented 4 months ago

That's the expected behavior if you don't change the truncate configuration. Take a look on the README file for more details.

fernvenue commented 4 months ago

Ah, thanks for your reply :)

bdim404 commented 4 months ago

That's the expected behavior if you don't change the truncate configuration. Take a look on the README file for more details.

Thx!