Your ROOT_URL in app.ini is https://git.cloudchain.link/ but you are visiting https://dash.bss.nz/open-source-mirrors/Sonarr/commit/03997e2a0d3c1418ed4723d839385e5a3fbf000f
You should set ROOT_URL correctly, otherwise the web may not work correctly.
4 changed files with
16 additions and
3 deletions
@ -98,6 +98,7 @@
<Reference Include= "System" />
<Reference Include= "System.Data" />
<Reference Include= "System.Drawing" />
<Reference Include= "System.Numerics" />
<Reference Include= "System.Xml" />
<Reference Include= "System.Xml.Linq" />
<Reference Include= "Microsoft.CSharp" />
@ -107,7 +107,7 @@ namespace NzbDrone.Core.Download.Clients.QBittorrent
item . TotalSize = torrent . Size ;
item . DownloadClient = Definition . Name ;
item . RemainingSize = ( long ) ( torrent . Size * ( 1.0 - torrent . Progress ) ) ;
item . RemainingTime = TimeSpan. FromSeconds ( torrent . Eta ) ;
item . RemainingTime = GetRemainingTime( torrent ) ;
item . OutputPath = _remotePathMappingService . RemapRemoteToLocal ( Settings . Host , new OsPath ( torrent . SavePath ) ) ;
@ -333,5 +333,15 @@ namespace NzbDrone.Core.Download.Clients.QBittorrent
_logger . Warn ( ex , "Failed to set inital state for {0}." , hash ) ;
}
}
protected TimeSpan ? GetRemainingTime ( QBittorrentTorrent torrent )
{
if ( torrent . Eta < 0 | | torrent . Eta > 365 * 24 * 3600 )
{
return null ;
}
return TimeSpan . FromSeconds ( ( int ) torrent . Eta ) ;
}
}
}
@ -1,4 +1,5 @@
using Newtonsoft.Json ;
using System.Numerics ;
using Newtonsoft.Json ;
namespace NzbDrone.Core.Download.Clients.QBittorrent
{
@ -13,7 +14,7 @@ namespace NzbDrone.Core.Download.Clients.QBittorrent
public double Progress { get ; set ; } // Torrent progress (%/100)
public ulong Eta { get ; set ; } // Torrent ETA (second s)
public BigInteger Eta { get ; set ; } // Torrent ETA (second s) (QBit contains a bug exceeding ulong limit s)
public string State { get ; set ; } // Torrent state. See possible values here below
@ -98,6 +98,7 @@
<Reference Include= "System.Core" />
<Reference Include= "System.Data" />
<Reference Include= "System.Drawing" />
<Reference Include= "System.Numerics" />
<Reference Include= "System.Web" />
<Reference Include= "System.Web.Extensions" />
<Reference Include= "System.Windows.Forms" />