Browse Source

Merge branch 'hotfix/0.21.31'

tags/release_0.21.31^0 release_0.21.31
JackDandy 5 years ago
parent
commit
7216bbbf86
  1. 9
      CHANGES.md
  2. 15
      gui/slick/js/loadingStartup.js
  3. 3
      sickbeard/providers/generic.py
  4. 10
      sickbeard/webserve.py

9
CHANGES.md

@ -1,4 +1,11 @@
### 0.21.30 (2020-04-30 10:20:00 UTC)
### 0.21.31 (2020-05-13 19:10:00 UTC)
* Fix correct type for hashlib call under py3
* Change improve loading logic, stop loop when reloading and only call location.reload(); once
* Fix RarBG under py3
### 0.21.30 (2020-04-30 10:20:00 UTC)
* Fix Milkie torrent provider breaking changes

15
gui/slick/js/loadingStartup.js

@ -12,6 +12,8 @@ var baseUrl = function () {
return $.SickGear.Root;
};
var reloading = false
var ajaxConsumer = function () {
var that = this;
that.timeoutId = 0;
@ -29,7 +31,8 @@ var ajaxConsumer = function () {
uiUpdateComplete(data.message);
})
.fail(function (jqXHR, textStatus, errorThrown) {
if (404 === jqXHR.status) {
if (404 === jqXHR.status && !reloading) {
reloading = true;
putMsg('Finished loading. Reloading page');
location.reload();
}
@ -37,10 +40,12 @@ var ajaxConsumer = function () {
})
.always(function (jqXHR, textStatus) {
clearTimeout(that.timeoutId);
if (that.pollInterval)
that.timeoutId = setTimeout(ajaxConsumer.checkLoadNotifications, that.pollInterval);
logInfo(that.pollInterval ? '^-- ' + that.pollInterval/1000 + 's to next work' : '^-- no more work');
logInfo('====');
if (!reloading){
if (that.pollInterval)
that.timeoutId = setTimeout(ajaxConsumer.checkLoadNotifications, that.pollInterval);
logInfo(that.pollInterval ? '^-- ' + that.pollInterval/1000 + 's to next work' : '^-- no more work');
logInfo('====');
}
});
}
};

3
sickbeard/providers/generic.py

@ -1768,7 +1768,8 @@ class TorrentProvider(GenericProvider):
@staticmethod
def _decode(data, c):
try:
result = ''.join([chr(int(str(bytearray([(8 * c)[i] ^ x for i, x in enumerate(data)])[i:i + 2]), 16))
fx = (lambda x: x, lambda x: str(x))[PY2]
result = ''.join([chr(int(fx(bytearray([(8 * c)[i] ^ x for i, x in enumerate(data)])[i:i + 2]), 16))
for i in range(0, len(data), 2)])
except (BaseException, Exception):
result = '|'

10
sickbeard/webserve.py

@ -1359,7 +1359,7 @@ class Home(MainHandler):
:param tvid_prodid:
:type tvid_prodid:
:param season:
:type season:
:type season:
:param episode:
:type episode:
:param absolute:
@ -1985,8 +1985,8 @@ class Home(MainHandler):
last_found = ('', ' since %s' % SGDatetime.fromordinal(
show_obj.last_found_on_indexer).sbfdate())[1 < show_obj.last_found_on_indexer]
show_message = (
'The master ID of this show has been <span class="addQTip" title="many reasons exist, including: ' +
'<br>show flagged as a duplicate, removed completely... etc">abandoned</span>%s, ' % last_found +
'The master ID of this show has been <span class="addQTip" title="many reasons exist, including: ' +
'<br>show flagged as a duplicate, removed completely... etc">abandoned</span>%s, ' % last_found +
'<a href="%s/home/edit-show?tvid_prodid=%s&tvsrc=0&srcid=%s#core-component-group3">replace it here</a>'
% (sickbeard.WEB_ROOT, tvid_prodid, show_obj.prodid)
+ ('', '<br>%s' % show_message)[0 < len(show_message)])
@ -6203,7 +6203,7 @@ class ConfigGeneral(Config):
# Create some values to seed md5
seed = str(time.time()) + str(random.random())
result = hashlib.new('md5', seed).hexdigest()
result = hashlib.new('md5', decode_bytes(seed)).hexdigest()
# Return a hex digest of the md5, eg 49f68a5c8493ec2c0bf489821c21fc3b
logger.log(u'New API generated')
@ -6515,7 +6515,7 @@ class ConfigSearch(Config):
sab_username=None, sab_password=None, sab_apikey=None, sab_category=None, sab_host=None,
nzbget_username=None, nzbget_password=None, nzbget_category=None, nzbget_host=None,
nzbget_use_https=None, nzbget_priority=None, nzbget_parent_map=None,
torrent_username=None, torrent_password=None, torrent_label=None, torrent_label_var=None,
torrent_username=None, torrent_password=None, torrent_label=None, torrent_label_var=None,
torrent_verify_cert=None, torrent_path=None, torrent_seed_time=None, torrent_paused=None,
torrent_high_bandwidth=None, torrent_host=None):

Loading…
Cancel
Save