* Adjusted the logic in `path_file_sanitize` to ensure the sanitized filename correctly appends the file suffix after the placeholder.
* This change prevents potential filename issues when handling file paths.
* Prevent writing `CoverDimensions.PxORIGIN` to metadata to avoid exceeding max file size (>16Mb).
* Ensure correct cover image is used based on `cover_dimension` settings.
* Introduced `url_ending_clean` to sanitize URLs by removing trailing "/u" or "?u".
* Updated `_process_url` and GUI search logic to utilize cleaned URLs for better validation and processing.
* Clarified the placeholder instructions for the "What happened?" field in the bug report template.
* Ensured consistency in language and improved readability for users submitting bug reports.
This commit refactors the codebase to improve readability and maintainability by updating enums and type annotations:
- ✨ **Replaced `StrEnum` attributes**: Removed explicit type declarations for enum values to simplify the code.
- 🛠️ **Introduced `AudioExtensionsValid` enum**: Added a new enum for valid audio file extensions.
- 🔄 **Enhanced type annotations**: Updated `FAVORITES` dictionary to include specific type hints for clarity.
- 🧹 **Updated references**: Replaced outdated `AudioExtensions` usage with the new `AudioExtensionsValid`.
These changes improve code clarity, enforce stricter typing, and enhance extensibility.
Introduces a new configuration option, `metadata_write_url`, to control whether the media file URL is included in metadata. Updates logic to respect this setting.
- ✨ **Feature**: Adds `metadata_write_url` to enable/disable URL writing in metadata.
- 🔧 **Logic Update**: Adjusts URL handling to check the new setting before including it.
- 📝 **Documentation**: Updates help descriptions to explain the new option.
This change improves flexibility in metadata customization.
Adds functionality to handle original image dimensions (`origin`) for album cover downloads.
- ✨ Added `PxORIGIN` option to cover dimension constants.
- 🔄 Updated cover image URL logic to support original dimensions.
- 🛠️ Improved cover data handling for more flexible metadata embedding.
This enhances customization and fidelity in cover image management.
Improves the application's icon handling by introducing multi-resolution
support, replacing a single PNG file with multiple resolution-specific icons.
- ✨ **Added** multiple resolution icons (16x16, 32x32, 48x48, 64x64, 256x256, 512x512).
- 🔄 **Updated** GUI setup to use multi-resolution icons for better scalability.
- 🗑️ **Removed** the old single-resolution `icon.png`.
This update ensures better compatibility and visual quality across
different platforms and screen resolutions.
This update introduces support for handling date-related format strings, improving the flexibility of media metadata formatting.
- ✨ **Feature**: Adds `_format_dates` function to handle date-related strings like `album_date`.
- 🛠️ **Enhancement**: Refactors `_format_durations` by isolating date-related logic into a new function.
- 📅 **Improvement**: Supports formatting `album_year` and `album_date` with proper checks for `Album` and `Track` types.
This improvement enhances media metadata formatting capabilities for more detailed date information.
Refactors the ID formatting logic to extend support for `video_id` and improve clarity.
- ✨ **Feature:** Adds support for `video_id` in ID formatting logic.
- ♻️ **Refactor:** Updates conditional checks for better readability.
- 🔧 **Metadata:** Updates `poetry.lock` content hash.
These changes enhance functionality and maintainability by accommodating additional media types.
This update introduces support for handling UPCs (Universal Product Codes) in metadata processing. It ensures that UPC information is extracted, stored, and written to the appropriate metadata tags for various formats.
- ✨ **Feature**: Adds UPC field to metadata handling.
- 🛠️ **Enhancement**: Updates metadata initialization to include UPC.
- 🗂️ **Tagging**: Implements UPC writing for supported file formats.
- ✅ **Compatibility**: Ensures proper handling when UPC is absent.
This improvement enhances metadata completeness and compatibility with systems requiring UPC data.
- Bump rich from 14.0.0 to 14.1.0
- Update tidalapi from 0.8.3 to 0.8.5
- Upgrade dev dependencies:
- deptry from 0.23.0 to 0.23.1
- mypy from 1.16.1 to 1.17.1
- pre-commit from 4.2.0 to 4.3.0
- tox from 4.27.0 to 4.28.4
- bandit from 1.8.5 to 1.8.6
- pylint from 3.3.7 to 3.3.8
- pillow from 11.2.1 to 11.3.0
* Added support for building GUI on macOS ARM64, Ubuntu, and Windows platforms.
* Restored previously commented-out build commands for better cross-platform compatibility.
* Eliminated the `gui-macos-dmg-intel` target from the Makefile.
* This target was a workaround for Intel Macs and is no longer necessary.
* Streamlined the `gui-macos-dmg` process for better clarity and maintenance.
* Changed the command to run `create-dmg` with `sudo` to ensure proper permissions on macOS.
* Added a sleep delay of 60 seconds to allow for any necessary processing time.
* Updated the command to `make gui-macos-dmg` for proper packaging.
* Introduced a 60-second delay before creating the DMG to ensure all processes are completed.
* Added a sleep command before creating the `.dmg` file to ensure proper execution.
* Modified the `hdiutil create` command to include `-debug` for troubleshooting.
- Introduced a new workflow for managing releases and test builds.
- Configured jobs for publishing, deploying documentation, and building GUI assets for multiple platforms.
- Set up environment variables and matrix strategy for cross-platform builds.
* Updated the Python version matrix in the tox job to only include 3.12.
* This change simplifies the testing process and focuses on the currently supported version.
Refactors the CLI structure to improve readability and maintainability:
- ♻️ Replaces `dl_fav_group` with `app_dl_fav` for better naming consistency.
- 🛠️ Restructures the `callback_app` function, removing redundancy.
- 🚀 Adds a URL detection mechanism to streamline `dl <URL>` command simulation.
- ✨ Enhances imports by adding `urlparse`.
These updates aim to simplify the codebase and improve user experience.
* Refactored `_handle_track_or_video` and `_handle_album_playlist_mix_artist` to use `typer.Context` instead of `Settings` directly.
* Improved clarity by centralizing settings retrieval through context.
* Adjusted `_process_url` and `_download` functions to align with the new context-based approach.
* Enhanced `_validate_and_prepare_media` method to support additional media types: `Album`, `Playlist`, `UserPlaylist`, and `Mix`.
* Updated media validation checks to ensure proper handling of unavailable media.
* Refactored `_validate_media_instance` to streamline media instance creation and validation.
* Removed redundant `_validate_and_prepare_media_collection` method for cleaner code.
* Improved validation and preparation of media collections for downloads.
* Refactored download context setup and execution logic for better clarity and maintainability.
* Added progress tracking for download tasks and improved handling of download futures.
* Reordered parameters in `item` method for clarity.
* Added `_validate_media_instance` method to streamline media validation.
* Enhanced `_prepare_file_paths_and_skip_logic` for better file handling.
* Introduced `_perform_actual_download` to encapsulate download logic.
* Improved error handling and logging throughout the download process.
* Renamed `_download` to `_get_media_urls` for better clarity on its purpose.
* Simplified URL extraction logic for `Track` and `Video` media types.
* Improved progress setup and error handling in the download process.
* Enhanced `_download_segments` and `_download_postprocess` methods for better readability and maintainability.