Find a file
Anthony Wang 8f09a59363
Handle case where the sourceUrl is mp3 not wav
Some songs have a mp3 instead of wav for their sourceUrl, for instance https://monster-siren.hypergryph.com/api/song/125014

To handle this, we need to always call choice_format() in download_song() and use AudioSegment.from_mp3 instead of AudioSegment.from_wav when doing the file conversion if the downloaded file is a mp3.
2023-10-06 23:11:10 -04:00
main.py Handle case where the sourceUrl is mp3 not wav 2023-10-06 23:11:10 -04:00
README.md Update README.md 2023-05-08 15:31:59 +08:00
requirements.txt Add files via upload 2023-05-04 17:45:58 +08:00
user_agent.txt Create user_agent.txt 2023-05-05 14:38:38 +08:00

Fixed from 1n0r1

Already test for using on Ubuntu & Windows in Python 3.
Download all songs, albums and fill out metadata, album, cover art, artists and even lyrics.

Fix and add function

  • Add the retry for the song didn't download for 100%
  • Add the timeout connection and retry function
  • Add the counter in the multiprocess to count the songs and album
  • Fix the tool use on Windows will be false because the album name have the space in the last
  • Add the delay in every download active
  • Add the User Agent to avoid the Program identify is a crawler
  • Add the choice to choose which the format of song or download all for flac and mp3

Error for not complete

  • retry to print the retry message.
    (Think may the message should add in the tqdm)

Note:

The API offers .mp3 and .wav, but the program convert .wav to .flac or .mp3 since .wav can't do metadata.

Requirements:

Python

ffmpeg

requests
tqdm
mutagen
pydub
pathvalidate
pylrc
Pillow

pip3 install -r requirements.txt or pip install -r requirements.txt

Runs:

  • python3 main.py or python main.py

  • Enter the format of the song, mp3 ,flac or all ( The songs offers .mp3 and .wav, the program will convert .wav to .flac or .mp3 since .wav can't do metadata. )

  • Choose the all for download the song all for mp3 and flac by transfer from wav.