Robert Dailey
d6fc96f247
fix: Allow quality group names to duplicate quality names.
...
Fixes #200
1 year ago
Robert Dailey
e6924c10e4
fix: Better error message when no config files are found
1 year ago
Robert Dailey
028f9be125
refactor: Remove TODO comment
...
This is in favor of a TODO item put in issue #202
1 year ago
Robert Dailey
a6e737fae9
fix: Improve repo clone performance by using shallow clones
...
Fixes #201 .
1 year ago
Robert Dailey
01fdc0639f
fix: Output more detail about HTTP 4xx "bad data" responses
1 year ago
Robert Dailey
aa8140add4
refactor: Print more information about QP updates
1 year ago
Robert Dailey
e0da419ffa
refactor: Address several analysis warnings
1 year ago
Robert Dailey
def934ebeb
refactor: Upgrade FileSystem to remove hack
...
This version of `System.IO.Abstractions` adds constructor options to
`MockFileSystem` that allows the removal of a hack put in place to
remove the temp directory so it does not interfere with unit test
expectations.
1 year ago
Robert Dailey
a6ceae65fc
refactor: Add SonarCloud Analyzer and fix analysis warnings
1 year ago
Robert Dailey
8596168757
feat: Add Allowed flag for QP upgrades
1 year ago
Robert Dailey
0652cfd800
fix: More robust handling of missing qualities list
...
When qualities are not specified by the user, qualities are not modified
if the profile exists in the service. If the profile does not exist yet,
then an error is shown. Qualities are required when the profile is being
created.
1 year ago
Robert Dailey
f40339e794
style: Code cleanup
1 year ago
Robert Dailey
1d7abb3977
refactor: Fix analysis warnings
1 year ago
Robert Dailey
ade5ee72b2
fix: Cutoff set properly when disabling upgrades
...
The `qualityprofile` API still performs validation on `cutoff` even when
`upgradeAllowed` is set to `false`. Because of this, we must still set
`cutoff` even if the user didn't specify `upgrade_allowed` and
`until_quality` in their configs. We do so by finding the first item in
the Items list, regardless of what that is. This fixes the HTTP 400 we
get when invoking the API with a `null` value for `cutoff`.
1 year ago
Robert Dailey
6bb7980827
fix: Preview and stat logging are more accurate
...
The assignment logic in the DTO objects changes the end result of what
gets synced. The preview and stat logic now first assigns config values
to the old DTO object to get a more accurate preview of what the new
values will be.
1 year ago
Robert Dailey
83cc0a77ee
refactor: Address resharper warnings
1 year ago
Robert Dailey
ce338e24f3
feat: Quality profile sync
...
Initial implementation with sync support for the following fields:
- Name
- Upgrade Allowed
- Min Format Score
- Cutoff
- Cutoff Format Score
- Items
Quality profiles are always created if they are defined under
`quality_profiles` at the top-level. Within a quality profile
configuration, Recyclarr will not modify quality profile fields if those
corresponding properties in the config are omitted.
1 year ago
Robert Dailey
31896828bc
chore: Disable changing expression body to normal body in code cleanup
1 year ago
Robert Dailey
84b9db13f4
refactor: Print full exception stack trace to console
...
Previously, the exception stack trace was omitted to simplify the
console output. However, some situations occurred where an exception was
logged but I couldn't tell where it came from. This made certain rare
bugs impossible to fix.
My philosophy at this point is: If something exceptional happens, we
don't really care about a "clean" console output anymore...
1 year ago
Robert Dailey
aebdb257d0
build: Upgrade FluentValidation and JetBrains.Annotations
1 year ago
Robert Dailey
7d757c0d5f
fix: Better error messages for non-existent config files
1 year ago
Robert Dailey
ea09ddfb00
fix: Markup issue when printing exception message
...
Just remove the special formatting for command runtime exception
messages.
Fixes #192
1 year ago
Robert Dailey
abcf4f7d8f
feat: api_key and base_url are now optional
...
These can be implicitly set via secrets that follow a naming convention.
1 year ago
Robert Dailey
9d085e33c2
refactor: Fix warning about unused getter
1 year ago
Robert Dailey
e47a335bb6
build: Upgrade multiple nuget packages
1 year ago
Robert Dailey
7c5da06e57
refactor: Remove instance name from cache storage path
...
This step is necessary to support merging of instance sections based on
a shared URL.
1 year ago
Robert Dailey
241eb261e9
test: Verify CF in cache but not in service
1 year ago
Robert Dailey
efd1863efd
refactor: Improve request/response body logging
1 year ago
Robert Dailey
9bdb5f364c
refactor: Improve logging for caching logic
1 year ago
Robert Dailey
67d604d8a0
refactor: Log format ID in logs
1 year ago
Robert Dailey
5a3b850f11
style: Code cleanup on CS files
1 year ago
Robert Dailey
c1b87f4b8b
fix: NRE due to null RootConfigYaml
1 year ago
Robert Dailey
58927728f8
fix: Clone/update config repo in config create command
1 year ago
Robert Dailey
7733b5e569
fix: Update default clone URL for trash guides repo
...
New URL: https://github.com/TRaSH-Guides/Guides.git
1 year ago
Robert Dailey
010c788e14
feat: Add migration step to delete old repo directory
1 year ago
Robert Dailey
406e0590a4
fix: Refactor and re-introduce capability enforcement
...
Fixes #189
1 year ago
Robert Dailey
f020459023
fix: Do not exit application when instance sync fails
1 year ago
Robert Dailey
0eb084b146
style: Code cleanup
1 year ago
Robert Dailey
f05ff6e04b
fix: Service cache now remembers CFs no longer in config
...
With `delete_old_custom_formats: false` and
`replace_existing_custom_formats: false`, if you comment out a CF in
your configuration, sync, uncomment it and sync again, you get an error
about duplicate CFs. This is because, once a CF is removed from the
configuration, it's also removed from the cache.
This change makes the cache more flexible. As long as a CF (created by
Recyclarr) exists either in the config OR in the service itself, it will
be kept in the cache. This means that temporarily disabling CFs in
configuration won't cause ownership issues.
1 year ago
Robert Dailey
f06a2c829a
refactor: Move Cache code files to Cli project
1 year ago
Robert Dailey
715d777f9e
refactor: replace morelinq with superlinq
1 year ago
Robert Dailey
2a28130599
fix: Do not unconditionally show deleted custom formats
...
When `delete_old_custom_formats` is `false`, we should not show deleted
custom formats.
1 year ago
Robert Dailey
d799da385e
fix: Regression caused reset_unmatched_scores: false to not be respected
1 year ago
Robert Dailey
fd8a2f570b
test: Add AutoFixture to global usings in Cli test project
1 year ago
Robert Dailey
11f3ab005b
feat: Continue running if git fetch fails
...
As long as there's a valid clone available and no other git commands
fail, we allow `git fetch` to fail and proceed processing commands. Even
if internet connectivity is down, that shouldn't necessarily prevent
sync from functioning.
The primary motivation for this change is that we expect the Trash
Guides repo to be relocated soon and I do not want that to cause the
program to stop working between the change and when I can update the
URL.
1 year ago
Robert Dailey
596fc72dfe
build: Remove debug option from sync run configuration
1 year ago
Robert Dailey
ee377e55fa
feat: Create configs from templates
1 year ago
Robert Dailey
ca941ac31d
refactor: Rename ConfigListCategory enum
1 year ago
Robert Dailey
d5c4a5d8ec
test: Remove unused FileSystem extension methods
1 year ago
Robert Dailey
e61a23e649
build: Upgrade all nuget packages
1 year ago
Robert Dailey
fe7773ea07
fix: Fix false-positive duplicate score warnings
...
When doing a `sync --preview`, new custom formats are not created and
thus they never get an ID greater than `0`. Because of this, a
dictionary that tracks duplicates based on ID would result in warnings
about duplicate scores that made no sense.
We now index by Trash ID instead of Format ID, which is more accurate.
1 year ago
Robert Dailey
018d5f0157
refactor: Add back ToString() overrides
...
This fixes a warning related to ToString() returning null.
1 year ago
Robert Dailey
ebdea5eabf
build: Add debug option to sync preview run config
1 year ago
Robert Dailey
6b3bf893b5
build: Use debug option with sync command
1 year ago
Robert Dailey
be7dac7e62
build: Upgrade all nuget packages
1 year ago
Robert Dailey
a8aaca42cc
feat: Support `*.yaml` extension
2 years ago
Robert Dailey
4f0e365dd5
test: Remove a few Refresh() calls no longer needed
...
Some Refresh calls happen automatically now for IFileInfo, etc. in
MockFileSystem.
2 years ago
Robert Dailey
2e1c7bff7d
build: Upgrade all nuget packages
2 years ago
Robert Dailey
9dbd0e56fa
build: Upgrade all nuget packages
2 years ago
Robert Dailey
6d90e8f293
chore: Remove attached folder from Rider project
2 years ago
Robert Dailey
deb6696622
refactor: Reorganize processor classes into subdirs
2 years ago
Robert Dailey
cdf4b27686
fix: Explicitly add System.Private.Uri package to resolve security issue
...
Resolves:
- CVE-2019-0981
- CVE-2019-0980
- CVE-2019-0657
2 years ago
Robert Dailey
cab505591f
chore: Remove unused code
2 years ago
Robert Dailey
8d2f582b38
refactor: Move all test projects under src/tests
...
This allows easier specification of test-specific msbuild properties
2 years ago
Robert Dailey
3823b0ec43
feat: Move config templates to new repository
2 years ago
Robert Dailey
7edcd77f98
fix: Use correct link in settings.yml template
2 years ago
Robert Dailey
3127ab3bb8
refactor: Delete auto-created temp dir in MockFileSystem
...
Needed because of this issue:
https://github.com/TestableIO/System.IO.Abstractions/issues/983
2 years ago
Robert Dailey
2c7f220a71
refactor: Add LeafDirectories() extension method for MockFileSystem
2 years ago
Robert Dailey
f1f9887042
refactor: Introduce config template repo settings
2 years ago
Robert Dailey
da35eef1ed
feat!: Restructure repository settings
2 years ago
Robert Dailey
b8ac93a464
refactor: Fix broken URLs
2 years ago
Robert Dailey
058c06504b
build: Upgrade nuget packages
2 years ago
Robert Dailey
96a278b06f
refactor: Make InstanceName non-nullable
2 years ago
Robert Dailey
fe9f98e435
refactor: Make exception class serializable
2 years ago
Robert Dailey
5609853321
feat!: Remove old migration steps
...
The following migration steps were removed:
- `MigrateTrashUpdaterAppDataDir`
- `MigrateTrashYml`
2 years ago
Robert Dailey
21a63ab8e1
feat!: replace_existing_custom_formats now defaults to true
2 years ago
Robert Dailey
c773a1a90b
refactor: Output log for each pipeline execution
2 years ago
Robert Dailey
3840f9c5ab
refactor: Improved error messaging for backward breaking config changes
2 years ago
Robert Dailey
cd6eda4055
feat!: Remove `reset_unmatched_scores` under quality score config
2 years ago
Robert Dailey
982de8806f
refactor: Remove V2 from some filenames
2 years ago
Robert Dailey
4a021a341b
feat!: Remove deprecated CLI commands
2 years ago
Robert Dailey
3e2ce37701
refactor: Delete unused source file
2 years ago
Robert Dailey
38e7980dbe
test: Fix or remove disabled tests
2 years ago
Robert Dailey
32ce3bde21
refactor: Fix serializable issue with CacheException
2 years ago
Robert Dailey
3c5b139523
refactor: Reduce cognitive complexity of method
2 years ago
Robert Dailey
134477ab46
refactor: Add timeouts to all regular expressions
2 years ago
Robert Dailey
286f4b95b1
refactor: Deprecation messages for old style array mapping
2 years ago
Robert Dailey
76040df597
refactor: Reorganize code and fix unit tests
2 years ago
Robert Dailey
6a16bd6045
refactor: Create interface for RuntimeValidationService
2 years ago
Robert Dailey
9a515aa820
build: Exclude config data project from dupe detection
2 years ago
Robert Dailey
5c98949edc
refactor: YAML configuration relies less on custom parsing code
...
This change was necessary to facilitate the ability to serialize
(create/modify) YAML configuration data. This is a prerequisite to
creating config templates and also GUI work in the future.
2 years ago
Robert Dailey
81bbc50ef7
build: Upgrade all packages
2 years ago
Robert Dailey
2652a5c663
build: Move Jetbrains.Annotations to projects
2 years ago
Robert Dailey
53595fc6ce
build: Move Spectre console analyzer to project file
2 years ago
Robert Dailey
b006122921
build: Move GitVersion.Build to projects
2 years ago
Robert Dailey
abb16f29e7
chore: Add file scope for CS files
2 years ago
Robert Dailey
761a247860
feat: Send API key via header instead of query param
2 years ago
Robert Dailey
5fc4da0f52
build: Upgrade Autofac and TestableIO packages
2 years ago
Robert Dailey
fbb5141c25
build: Upgrade YamlDotNet
2 years ago
Robert Dailey
40ed9f366c
build: Upgrade all nuget packages
2 years ago
Robert Dailey
29ca61f68f
refactor: Address several resharper analysis issues
2 years ago
Robert Dailey
39f106c72b
refactor: Fix warning related to FluentValidation & NRT
2 years ago
Robert Dailey
9d53fd0152
fix: Do not assume only one field element in CF specifications
...
For most CF specifications, there is only one element in the `fields`
array, which has a `value` property inside of each of its objects. One
particular specification, however, deviates from this assumption. The
"SizeSpecification" has been observed with *two* field objects.
Logic for parsing custom format CFs no longer assumes that the fields
property may only have one element in it.
Fixes #178
2 years ago
Robert Dailey
bebd28bc11
build: Upgrade FluentValidation
2 years ago
Robert Dailey
fc6a186809
build: Upgrade morelinq
2 years ago
Robert Dailey
93a8c8bc22
build: Upgrade all nuget packages
2 years ago
Robert Dailey
1a16432341
refactor: Remove inappropriate usage of `required` in CliSettings
2 years ago
Robert Dailey
f7bfab065d
fix: Show default value in `config list` help
2 years ago
Robert Dailey
dc93b10e64
test: Add await where necessary
2 years ago
Robert Dailey
e54cef0859
feat: `config list local` implemented
2 years ago
Robert Dailey
ce481e0d1f
refactor: Config loader no longer reuses state
2 years ago
Robert Dailey
f5386dfeda
fix: Template config listing is no longer reversed
2 years ago
Robert Dailey
f6f6ea3192
style: Solution-wide code cleanup
2 years ago
Robert Dailey
a3c172cf02
feat: Add config list templates command
...
Lists template YAML files in the trash repo.
2 years ago
Robert Dailey
902fbad4bf
chore: Remove unused run configuration
2 years ago
Robert Dailey
a934e68227
fix: Enable strict parsing to error on unknown CLI options
2 years ago
Robert Dailey
7c15c14f40
refactor: More concise usage of UsedImplicitly in SyncCommand
2 years ago
Robert Dailey
fe2b062ba7
fix: Consistently set FormatIDs to avoid incorrect logs
2 years ago
Robert Dailey
f298926353
fix: Use INF instead of DBG for score update log
2 years ago
Robert Dailey
58bbb94a44
build: Upgrade all nuget packages
2 years ago
Robert Dailey
a22d6dec33
fix: Log janitor updated to clean up logs in new 'cli' dir
2 years ago
Robert Dailey
e222f547cc
test: Fix config loader test
...
No exception is thrown when a non-empty config results in no usable
configuration.
2 years ago
Robert Dailey
c82894291f
fix: Do not fail on empty service type sections
2 years ago
Robert Dailey
bf9a08c19c
test: Fix broken unit test
2 years ago
Robert Dailey
cffb8d783a
refactor: Convert processors/updaters to pipelines
2 years ago
Robert Dailey
e3d6d4f79a
refactor: Remove DI for IServiceConfiguration in API services
2 years ago
Robert Dailey
bcc65857df
refactor: Split Sonarr/Radarr orthogonally into service-based classes
...
Instead of organizing logic using service, such as Sonarr or Radarr,
organize it using function. So now logic is broken up by Custom Format,
Release Profile, and Quality Size.
2 years ago
Robert Dailey
7dec45a07a
refactor: Eliminate generics for config type
2 years ago
Robert Dailey
289d661247
refactor: Silence warnings in _Layout.cshtml
2 years ago
Robert Dailey
c0bad938d7
feat: Split and restructure CLI logs
2 years ago
Robert Dailey
5adb966aa9
refactor: Add serilog to implicit usings
2 years ago
Robert Dailey
94b000c55f
build: Upgrade nuget packages for tests
2 years ago
Robert Dailey
adeb478777
fix: Exception when either Sonarr or Radarr configs are empty
2 years ago
Robert Dailey
7be4189378
refactor: Code cleanup
2 years ago
Robert Dailey
d66aa8ba44
refactor: Solution-wide code cleanup
2 years ago
Robert Dailey
86eca33eb3
refactor: Move Commands.Shared CS files up a level
...
This is to address a roslyn warning.
2 years ago
Robert Dailey
ce6afa4157
refactor: Fix more analysis issues
2 years ago
Robert Dailey
c226097cb5
refactor: Clone URL is now a Uri object
2 years ago
Robert Dailey
c45860d280
refactor: BaseUrl type is now Uri instead of string
2 years ago
Robert Dailey
7185cc5844
refactor: Fix various analysis issues
2 years ago
Robert Dailey
5d0db006ba
chore(style): Overhaul editorconfig
2 years ago
Robert Dailey
7bc5d407e3
build: Upgrade multiple nuget packages
2 years ago
Robert Dailey
4275336a8a
refactor: Fix unused member variable inspection issue
2 years ago
Robert Dailey
c05d73a84b
refactor: Remove redundant config validation
...
Validation already happens in ConfigParser, then SyncProcessor does not
need to do it as well.
2 years ago
Robert Dailey
8e22a5d561
test: Verify exceptional case for env var parsing
2 years ago
voltron4lyfe
aa523a0e14
feat: Enable referencing environment variables in config
...
Closes #145
Closes #154
2 years ago
Robert Dailey
6e397aefcf
test: Restructure tests
2 years ago
Robert Dailey
b9dc15f6a7
refactor: Relocate secrets yaml behavior to secrets dir
2 years ago
Robert Dailey
6fb1d4ad66
feat: Improved preview output for release profiles
2 years ago
Robert Dailey
964aeb8380
feat: Improved preview output for custom formats
2 years ago