Add a new Backfill plugin, accessed from the Task plugin#192
Open
logicalChimp wants to merge 7 commits into
Open
Add a new Backfill plugin, accessed from the Task plugin#192logicalChimp wants to merge 7 commits into
logicalChimp wants to merge 7 commits into
Conversation
053fde6 to
3edb13c
Compare
…r appears Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
3edb13c to
0128df6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
NOTE: This is a 'scratch a personal itch' request, and an excuse to get familiar with Typescript, UI development, and using AI coding asissts.... hence the lack of associated feature request, etc. I apologise for the lack of discussion on Chat etc, but I only started working on it a day or two ago.
Motivation for changes:
I often miss the start of a new series, meaning the first few episodes no longer appear in the default RSS tracker view I use. This plugin makes it simple to 'backfill' the series, by selecting the relevant task from the Tasks view (that the series has been added to), and running it once using a custom RSS url to fetch the 'missing' episodes.
This approach was chosen due to the relative complexity of my task definition (including handling series that don't include the series-number for the first series, as well as the deluge configuration (and moving to custom folders per series after download, etc) - cloning the existing task and changing the RSS url means the same logic gets applied to the backfill episodes, and they end up in the same folders, etc.
The plugin works by:
By default, the task name will be populated into the 'Backfill task name' field with the suffix 'backfill', and the 'Auto Update' checkbox will be checked. If the auto-update checkbox is checked, the 'Backfill Task Name' will incorporate the chosen 'Task Series' value (if a series name is chosen), and/or any values added into the 'Extra Query Params' field, in order to make a more unique and descriptive task-name. This behaviour can be stopped by unchecking the 'auto update' checkbox.
By default, the RSS url from the selected task config will be populated into the 'Backfill RSS URL' field, and the URL parsed to populate the 'Query Params' list. If the user selects a query param from the list, the 'auto update' checkbox will be checked. Any existing (or future) Task Series name and/or Extra Query Params values will be appended to the chosen query parameter in the Backfill RSS URL. This behavious can be stopped by unchecking the 'auto update' checkbox.
Note: the above behaviour for the Backfill RSS URL is intended to make it easier to generate a 'backfill url' for RSS feeds that use a query/search style URL to identify episodes. The encoding of values (task series name and/or extra query params) is done using 'Form Encoding' (URL encoding, followed by a manual conversion of %20 -> '+').
Note: both the original 'Source Task Config' and the updated/modified 'Backfill Task Config' are editable, but they have been collapsed by default to save page-space.
A full suite of unit tests has been included, to cover the functionality and diferent 'sequence-of-actions' for the UI.
Detailed changes:
Addressed issues:
NA
Implemented feature requests:
NA
To Do:
Currently, all Task executions - including those for 'deleted' tasks such as the one-time Backfill tasks generated by this plugin - appear in the 'Latest' view on the Tasks page.
Time permitting, I will raise a separate PR to update the Tasks plugin 'Latest' view to not show 'deleted' tasks by default. This will be achieved by adding a 'show deleted' checkbox (unchecked by default), and then fetching the list of tasks from the Tasks api, and comparing the list of Task Executions against the list of tasks - any execution that does not have a matching task will be tagged as 'deleted', and not displayed unless the 'Show deleted' checkbox is ticked.