Your ROOT_URL in app.ini is https://git.cloudchain.link/ but you are visiting https://dash.bss.nz/open-source-mirrors/recyclarr/commit/fd216c1b6003fcc3a5abbd7d64ac58bed44ecbe8
You should set ROOT_URL correctly, otherwise the web may not work correctly.
3 changed files with
15 additions and
4 deletions
@ -12,6 +12,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Custom Formats: Updates that conflict with existing CFs in Sonarr/Radarr are now skipped and a
warning is printed.
- When changing instance URLs, use new cache data to avoid mismatched custom formats on next sync.
## [4.1.0] - 2022-12-30
@ -45,6 +45,6 @@ public class CacheStoragePathTest : IntegrationFixture
var sut = scope . Resolve < CacheStoragePath > ( ) ;
var result = sut . CalculatePath ( "obj" ) ;
result . FullName . Should ( ) . MatchRegex ( @".*[/\\]thename [/\\]obj\.json$") ;
result . FullName . Should ( ) . MatchRegex ( @".*[/\\]thename _[a-f0-9]+ [/\\]obj\.json$") ;
}
}
@ -26,16 +26,26 @@ public class CacheStoragePath : ICacheStoragePath
_hash = FNV1aFactory . Instance . Create ( FNVConfig . GetPredefinedConfig ( 32 ) ) ;
}
private string Build ServiceGuid( )
private string Build UniqueServiceDir( string? serviceName )
{
return _hash . ComputeHash ( Encoding . ASCII . GetBytes ( _config . BaseUrl ) ) . AsHexString ( ) ;
// In the future, once array-style configurations are removed, the service name will no longer be optional
// and the below condition can be removed and the logic simplified.
var dirName = new StringBuilder ( ) ;
if ( serviceName is not null )
{
dirName . Append ( $"{serviceName}_" ) ;
}
var guid = _hash . ComputeHash ( Encoding . ASCII . GetBytes ( _config . BaseUrl ) ) . AsHexString ( ) ;
dirName . Append ( guid ) ;
return dirName . ToString ( ) ;
}
public IFileInfo CalculatePath ( string cacheObjectName )
{
return _paths . CacheDirectory
. SubDirectory ( _serviceCommand . Name . ToLower ( CultureInfo . CurrentCulture ) )
. SubDirectory ( _config . Name ? ? BuildServiceGuid ( ) )
. SubDirectory ( BuildUniqueServiceDir( _config. Name ) )
. File ( cacheObjectName + ".json" ) ;
}
}