This utility automates the process of re-downloading failed osu! beatmap files by opening their download links in the default web browser. It is intended to assist users in efficiently retrying downloads for beatmaps that previously failed to import.
-
Failed Beatmaps Folder:
- Place all failed
.oszfiles in thefailedfolder, located in the same directory asmain.py. In osu!, the failed import folder is found in the Songs directory and is namedfailed. If you do not have afailedfolder, it means none of your imports have failed. - Note: You can either manually create the
failedfolder or simply run the program once; it will automatically create the folder if it does not exist.
- Place all failed
-
Extracting Beatmap IDs:
- The program scans the
failedfolder for.oszfiles and extracts the numeric beatmap IDs from their filenames. - The IDs are sorted in ascending order.
- The program scans the
-
Download List:
- All sorted beatmap IDs are written to
downloading.txtprior to initiating the download process.
- All sorted beatmap IDs are written to
-
Automated Download:
- For each beatmap ID, the program opens the corresponding download URL (
https://api.nerinyan.moe/d/{id}) in the default web browser. - A status bar is displayed in the terminal, showing the current progress as a hash-based progress bar, the number of downloads completed, and the percentage finished.
- The program waits a few seconds between each download to allow the browser to initiate the download.
- For each beatmap ID, the program opens the corresponding download URL (
-
Cleanup:
- After all downloads are attempted, the
downloading.txtfile is cleared.
- After all downloads are attempted, the
- Ensure Python 3 is installed on your system.
- Place your failed
.oszfiles in thefailedfolder. - Run the script:
python main.py
- The browser will automatically open each download link in sequence.
- Adjust the sleep durations in the script if your downloads start too slowly or too quickly.
- The script does not verify if the downloads succeed; it simply opens the links.
- The
downloading.txtfile is used for tracking and is cleared after the script completes.
- Python 3.x
- A web browser installed and set as default, with a configured default download location
You may modify the script to better suit your workflow as needed.