Release Notes
Added
-
Configuration File Creation: Added logic to automatically create the configuration file if it does not exist. The application now ensures the config file is created in the same directory as the executable or script.
-
Manual Filename Option: Added an option to manually set the filename for downloads or use a custom template string. Users can now specify a filename directly in the UI, providing greater flexibility.
Updated
-
Configuration File Path Handling:
- Updated the
CONFIG_FILE_PATH
to be set relative to the executable or script directory, ensuring it is created alongside the.exe
when compiled. - Added a check to determine if the script is running as a compiled executable or as a script and adjusted the config file path accordingly.
- Commit: ac2679a
- Updated the
-
Path Normalization:
- Improved path normalization by using
os.path.normpath
to ensure paths are consistently formatted based on the operating system.
- Improved path normalization by using
-
YT-DLP Library Usage:
- Switched from depending on the
yt-dlp
executable to using theyt-dlp
library directly within the application. This change simplifies the setup process by removing the need for an external executable and integratesyt-dlp
functionality more seamlessly. - Commit: 6c0e2c5
- Switched from depending on the
-
FFmpeg Path Handling:
- Implemented a method to check if
ffmpeg
is available in the system's PATH by running theffmpeg -version
command. Ifffmpeg
is set to"ffmpeg"
in the configuration but is not found in PATH, the application now raises an appropriate exception prompting users to addffmpeg
to PATH or specify a custom path. - Commit: bd0c6b4
- Implemented a method to check if
Fixed
- Error Handling:
- Enhanced error handling in the
save_config
method to catch and print IOError exceptions if there's an issue saving the configuration file. - Fixed issues where the application could incorrectly handle FFmpeg paths, ensuring better handling of both default and custom paths.
- Enhanced error handling in the
Code Changes
-
DownloadWorker
Class:- Updated to use the
yt-dlp
library directly instead of the executable. - Added logic to handle manual filename input and custom template strings.
- Implemented
is_ffmpeg_in_path
method to check ifffmpeg
is in the PATH.
- Updated to use the
-
save_config
Method:- Updated to create necessary directories if they don't exist and handle file writing with proper encoding and error catching.