- Introduced DEBRID_CACHE_CHECK_RATIO to control the minimum ratio of cached to total torrents for skipping availability checks on the debrid service.
- Updated the stream endpoint to utilize the new ratio in the availability check logic, enhancing performance by reducing unnecessary checks.
- Enhanced startup logging to include the new DEBRID_CACHE_CHECK_RATIO for better visibility of settings.
- Modified the playback endpoint to accept 'name' as a query parameter instead of a path parameter, improving URL structure and flexibility.
- Updated the stream URL generation to include the 'name' query parameter for better handling of playback requests.
- Added logging for Gunicorn preload app and the status of disabling torrent streams.
- Improved database logging to include read replicas when applicable.
- Updated logging for anime mapping settings to enhance visibility during startup.
- Eliminated the 'force_primary' parameter from database fetch calls in the AnimeMapper class to streamline query execution.
- This change enhances code clarity and maintains consistency with recent refactoring efforts.
- Enhanced the exception handling in the TorrentUpdateQueue to log specific errors encountered during the processing of remaining queue items during shutdown.
- This change improves the visibility of issues that may arise when the queue is being processed.
- Updated the StremthruScraper to utilize the anime_mapper for retrieving IMDb IDs from Kitsu, improving the accuracy of media ID handling.
- Adjusted the API request to use the mapped IMDb ID when available, ensuring better integration with the anime service.
- Moved the setting of 'is_running' to after the queue join in the stop method for clearer logic flow.
- This change ensures that the queue is fully processed before marking the queue as not running.
- Reorganized the try-except structure in the _refresh_loop method for better readability and clarity.
- Ensured that the error handling for asyncio.CancelledError and other exceptions is properly nested within the loop.
- Changed the data type of 'kitsu_id' in the anime_mapping_cache table from TEXT to INTEGER for better consistency.
- Simplified the handling of 'kitsu_id' in the MetadataScraper and AnimeMapper classes by removing unnecessary string conversions.
- Changed the database log level icon from "🗄️" to "💾" for better representation.
- Modified the log parsing regex pattern to allow for more flexible matching of log levels.
- Reintroduced the creation of the db_maintenance table in the appropriate section of the database setup process.
- Ensured that the table is created after the version migration to maintain database integrity.
- Reformatted the constructor for improved readability.
- Added 'force_primary' parameter to 'execute' and 'execute_many' methods to control query execution behavior.
- Improved formatting in '_next_replica' method for better code clarity.
- Simplified the logic for inserting new entries into the first_searches table.
- Removed redundant database fetch operation to improve performance and clarity.
- Removed signal handling from main.py for graceful shutdown.
- Added stop methods to AnimeMapper, AddTorrentQueue, and TorrentUpdateQueue for better resource management during shutdown.
- Updated lifespan in app.py to ensure proper shutdown of services.