Commit Graph

587 Commits

Author SHA1 Message Date
oop7 b9b0285e95 Refactor config handling to use ConfigManager
Replaced direct usage of load_config and save_config with ConfigManager in ytsage_utils.py and ytsage_dialogs_update.py. Removed legacy config functions from ytsage_utils.py to centralize configuration management and improve maintainability.
2026-01-24 16:54:08 +02:00
oop7 02ede913d2 Refactor analysis to use QThread for thread safety
Replaces the use of Python's threading with a dedicated QThread-based AnalysisThread for URL analysis, ensuring all UI updates are performed via Qt signals for thread safety. Adds cancellation support for analysis, improves error handling, and updates the main window's close event to properly terminate the analysis thread if running. This refactor enhances stability and responsiveness of the GUI during analysis operations.
2026-01-24 16:50:24 +02:00
oop7 217c03379e Add ytsage_stylesheet.py to project structure in README
Updated the README to include the new ytsage_stylesheet.py file under the YTSage GUI directory, reflecting the addition of stylesheet definitions to the project.
2026-01-24 16:30:15 +02:00
oop7 3ae18678e8 Remove pyglet from dependencies list in README
The pyglet library has been removed from the dependencies table in the README, indicating it is no longer used for audio playback in the project.
2026-01-24 16:28:25 +02:00
oop7 64560fabb2 Replace pyglet with QtMultimedia for audio playback
Removed pyglet dependency and migrated notification sound playback to use PySide6.QtMultimedia's QMediaPlayer and QAudioOutput. Updated workflow and requirements files to remove pyglet and ensure PySide6.QtMultimedia is included in build steps.
2026-01-24 16:25:52 +02:00
oop7 d5d7a0186d Refactor analysis logic into AnalysisMixin
Moved all analysis-related methods from YTSageApp in ytsage_gui_main.py to a new AnalysisMixin in ytsage_gui_analysis.py. This improves code organization and separation of concerns by isolating analysis logic from the main application class.
2026-01-24 14:00:13 +02:00
oop7 370836b814 Refactor GUI styles to use centralized StyleSheet class
Moved all inline widget style definitions in ytsage_gui_main.py to named constants in the StyleSheet class in ytsage_stylesheet.py. This centralizes and simplifies style management, improves maintainability, and ensures consistent theming across the application.
2026-01-24 13:46:16 +02:00
oop7 9759fa565f Refactor UI startup and stylesheet handling
Moved the main application stylesheet to a new src/gui/ytsage_stylesheet.py module and applied it via StyleSheet.MAIN. Deferred blocking startup checks (FFmpeg, yt-dlp, Deno, updates) until after the UI is shown to improve responsiveness. Improved subtitle file deletion logic and added destination filename capture in downloader. Added custom style for auto-update checkbox in updater dialog.
2026-01-24 13:35:02 +02:00
oop7 4d4d9e10b9 Refactor updater checks to use QThread for async operations
Replaces manual threading for FFmpeg and Deno version checks with dedicated QThread subclasses (FFmpegCheckThread and DenoCheckThread). This improves integration with the Qt event loop, enables use of signals and slots for UI updates, and enhances error handling.
2026-01-24 12:57:37 +02:00
oop7 a871ded15f Move update check to background thread
Refactored the update checking logic into a QThread subclass to prevent blocking the UI during network requests. The update check now runs asynchronously, and the dialog is shown via a signal when an update is available.
2026-01-24 12:52:48 +02:00
oop7 e2c4dfea4e Increase menu button area in history delegate
Expanded the clickable area for the menu button in HistoryDelegate to 60x50px and adjusted text width accordingly. This improves usability and addresses issues with the left side of the button not responding to clicks.
2026-01-21 18:10:34 +02:00
oop7 7c2e461141 Refactor HistoryManager to use persistent DB connection
Replaces per-operation SQLite connections with a persistent connection for improved efficiency and thread safety. Adds additional indexes for faster search on title, channel, and URL. Refactors all database access methods to use the persistent connection and simplifies transaction handling.
2026-01-21 18:05:17 +02:00
oop7 5f17fabc50 Refactor history dialog to use virtualized list and SQLite
Replaces the history dialog's widget-per-entry approach with a virtualized QListView using a custom model and delegate for improved performance. Switches the HistoryManager backend from JSON file storage to SQLite, including automatic migration of legacy data. Adds support for efficient search, thumbnail caching, and context menu actions in the new UI.
2026-01-21 17:56:56 +02:00
oop7 29f713cf17 Refine HistoryEntryWidget layout and sizing
Adjusted padding, margin, and spacing for a more compact layout. Standardized the thumbnail size to 240x135 (16:9 ratio) and reduced the menu button size for better visual balance.
2026-01-21 17:19:49 +02:00
oop7 ea54f469ac Improve history loading and thumbnail caching UX
Refactors the history loading process to emit entries as soon as they are loaded, allowing the UI to display immediately. Thumbnail downloads are now handled in the background, with widgets updated via a new signal when thumbnails are cached. This prevents UI freezes and improves responsiveness by showing placeholders until thumbnails are available.
2026-01-21 17:16:48 +02:00
oop7 a92ffd3b01 Download video thumbnails asynchronously in GUI
Refactored thumbnail downloading to use a QThread for asynchronous operation, preventing UI blocking. Added ThumbnailDownloadThread class and updated VideoInfoMixin to handle threaded download and error reporting.
2026-01-21 17:16:35 +02:00
oop7 0d1eb35ba2 Add debug log for yt-dlp command execution
Inserted a debug log statement to output the full yt-dlp command before execution. This will help diagnose issues related to command construction and subprocess invocation.
2026-01-21 15:15:14 +02:00
oop7 9a81c4b564 Update badge labels in README
Changed the 'pypi downloads' and 'github downloads' badge labels to 'downloads' for consistency and improved readability.
2026-01-17 22:16:35 +02:00
oop7 ca7ac168fe Update badges in README with download stats
Replaces the generic downloads badge with separate PyPI and GitHub downloads badges for improved clarity. Enhances visibility of project statistics in the README.
2026-01-17 22:13:08 +02:00
Mohamed 1e5157bbad Sync with the beta branch 2026-01-17 22:06:10 +02:00
oop7 6a4264eeab Add contents write permission to release workflow
Updated the release-all GitHub Actions workflow to include 'contents: write' permission, enabling the workflow to perform actions that require write access to repository contents.
2026-01-17 22:04:23 +02:00
oop7 5ed67cb32f Bump version to 5.0.0b
Update the __version__ string to 5.0.0b to reflect the next major beta release.
2026-01-17 21:58:50 +02:00
oop7 d087c306f2 Add 'analyzing_fetching_first_video' translation key
Introduced the 'analyzing_fetching_first_video' string to all supported language files for consistent UI messaging during the analysis process.
2026-01-17 21:48:45 +02:00
oop7 67fdb508f4 Optimize playlist extraction with yt-dlp flat-playlist
Switches to using yt-dlp's --flat-playlist and --dump-single-json for faster initial playlist info extraction. Now fetches minimal info for all videos quickly, then retrieves full details for the first video only to populate format information, improving performance and reducing unnecessary data processing.
2026-01-17 21:43:08 +02:00
oop7 ffb938b181 Add playlist filter and show video durations in selection dialog
Introduces a filter input to the PlaylistSelectionDialog for searching videos by title and displays video durations next to each entry. Updates English translations to support the new filter placeholder and analysis status message.
2026-01-17 21:43:01 +02:00
oop7 2b7cce1333 Add threaded loading and spinner to history dialog
Introduces a HistoryLoaderThread to load history entries and pre-fetch thumbnails in the background, preventing UI freezes. Adds a loading spinner and disables the 'Clear All' button while loading, improving user experience during history retrieval.
2026-01-17 21:26:26 +02:00
oop7 fd192455f5 Handle Path objects in config JSON serialization
Added a custom converter to serialize Path objects as strings when saving the application configuration to JSON. This prevents serialization errors if Path objects are present in the config.
2026-01-17 21:21:06 +02:00
oop7 f8f2910f06 Fix f-string backslash SyntaxError in AboutDialog
Refactored AboutDialog to avoid backslashes in f-string expressions by assigning HTML links to variables before formatting. This resolves a SyntaxError encountered when running YTSage with Python 3.11.
2026-01-17 21:10:01 +02:00
oop7 c16e84105e Increase subprocess timeout to 300 seconds
Extended the timeout for the subprocess running yt-dlp from 60 to 300 seconds to accommodate longer-running download or processing tasks.
2026-01-17 21:01:52 +02:00
oop7 26d063327c Fix indentation for zip extraction block
Corrected the indentation so that the extraction of the executable occurs within the context of the open zip file. This ensures the file is extracted while the zip is accessible, preventing potential errors.
2026-01-07 18:45:51 +02:00
oop7 a4df946169 Fix extraction path for Deno executable
Changed the extraction target directory for the Deno executable to use the parent of DENO_APP_BIN_PATH instead of APP_BIN_DIR, ensuring the executable is placed in the correct location.
2026-01-07 18:32:20 +02:00
oop7 07e3525042 Add env var override for DENO_APP_BIN_PATH on Linux
Allows DENO_APP_BIN_PATH to be set via environment variable, supporting Flatpak and custom setups. Also ensures parent directories for both yt-dlp and deno binaries are created if custom paths are set.
2026-01-07 18:14:05 +02:00
oop7 b3144798f4 Add Flatpak-specific desktop file and env var to build
Introduces creation of a Flatpak-specific desktop file with correct Exec and Icon fields. Adds DENO_APP_BIN_PATH environment variable to Flatpak manifest and updates install commands to use the new desktop file.
2026-01-07 18:13:43 +02:00
oop7 c7751edd91 Add DENO_APP_BIN_PATH env override and Flatpak support
Introduces support for overriding DENO_APP_BIN_PATH via environment variable, enabling compatibility with Flatpak packaging. Updates the build workflow to set the DENO_APP_BIN_PATH environment variable and ensures parent directories for custom binary paths are created if needed.
2026-01-07 18:11:06 +02:00
oop7 67d0919237 Add Flatpak-specific desktop file to build workflow
Introduces creation of a dedicated desktop file for Flatpak packaging in the build-linux workflow. Ensures the Exec and Icon fields conform to Flatpak requirements and updates the install step to use the new desktop file.
2026-01-07 17:40:07 +02:00
oop7 2574ed0467 Add Flatpak badge to Linux install options
Included a Flathub badge in the Linux installation table to indicate Flatpak bundle availability.
2026-01-06 17:23:31 +02:00
oop7 f7cf752fb2 Bump version to 4.9.8b
Update the __version__ string in src/__init__.py to 4.9.8b to reflect the latest changes.
2026-01-06 17:22:14 +02:00
oop7 c9691c6a56 Update Flatpak runtime to version 6.10 in CI
Changed the Flatpak runtime and SDK version from 6.6 to 6.10 in the build-linux GitHub Actions workflow to ensure compatibility with the latest KDE platform.
2026-01-06 16:50:46 +02:00
oop7 f1d1a68d32 Merge branch 'beta' 2026-01-06 16:14:15 +02:00
oop7 0b5b5b3189 Add Flatpak build support and env override for yt-dlp path
Introduces a Flatpak packaging step to the Linux CI workflow and updates ytsage_constants.py to support overriding the yt-dlp binary path via the YTDLP_APP_BIN_PATH environment variable, which is critical for Flatpak compatibility. Also ensures the custom yt-dlp directory is created if the environment variable is set.
2026-01-06 16:13:21 +02:00
oop7 462252b452 Fix formatting in workflows section of README
Corrected indentation and line formatting for the workflows section in the README to improve readability and consistency.
2026-01-06 16:04:59 +02:00
oop7 0edc64a5e9 Add release-all.yml to CI workflow list in README
Documented the master release workflow (release-all.yml) in the CI/CD section of the README for better visibility of available workflows.
2026-01-06 16:02:59 +02:00
oop7 45ce4ba69c Update CI/CD README for manual workflow triggers
Revamps the CI/CD documentation to reflect the new manual workflow dispatch system, replacing tag-based triggers. Adds detailed instructions for running full or platform-specific builds, clarifies artifact naming, and updates configuration and process notes to match the current GitHub Actions setup.
2026-01-06 16:02:11 +02:00
oop7 16e61c5d6f Refactor release workflows and add release-all trigger
Refactored build workflows for Linux, macOS, and Windows to use workflow_dispatch and workflow_call with explicit version input, replacing tag-based triggers. Updated release steps to use the provided version input for tagging and naming. Added a new release-all workflow to trigger all platform builds with a single version input.
2026-01-06 15:52:58 +02:00
oop7 192841a836 Bump version to 4.9.7
Update the __version__ string in src/__init__.py from 4.9.7b to 4.9.7, indicating a release from beta to stable.
2025-12-26 23:39:28 +02:00
oop7 4aa0a7b70e Update macOS ARM64 descriptions in README
Changed the descriptions for macOS ARM64 APP and DMG formats from 'for ARM64' to 'for Apple Silicon' for improved clarity in the README.
2025-12-11 13:29:31 +02:00
oop7 d8c754382f Set macOS build to run only on macos-latest
Removed the matrix strategy for multiple macOS runners and set the workflow to use only macos-latest. Simplifies the build process and reduces resource usage.
2025-12-11 13:24:37 +02:00
oop7 ba8011ce44 Update macOS build matrix to use macos-14-large
Replaces macos-15-large with macos-14-large in the GitHub Actions build matrix for improved compatibility or resource availability.
2025-12-11 12:18:20 +02:00
oop7 35c58bfcfa Update macOS build matrix to use macos-15-large
Replaces 'macos-15' with 'macos-15-large' in the GitHub Actions build matrix to utilize the larger runner for macOS 15 builds.
2025-12-11 12:15:30 +02:00
oop7 ce3fd4217d Update macOS build matrix in CI workflow
Replaces specific macOS versions with 'macos-latest' and 'macos-15' in the build matrix to ensure compatibility with newer macOS runners.
2025-12-11 11:28:39 +02:00