mirror of
https://github.com/SickGear/SickGear.git
synced 2025-01-05 17:43:37 +00:00
Add a general config setting to allow adding incomplete show data.
This commit is contained in:
parent
624485d9a6
commit
4171143cfc
7 changed files with 36 additions and 14 deletions
|
@ -54,6 +54,7 @@
|
|||
* Remove FreshOnTV (TvT) torrent provider
|
||||
* Remove Strike torrent provider
|
||||
* Change increase the scope and number of non release group text that is identified and removed
|
||||
* Add a general config setting to allow adding incomplete show data
|
||||
|
||||
[develop changelog]
|
||||
Enable Alpha Ratio again now that the secure login page over https is fixed
|
||||
|
|
|
@ -72,7 +72,7 @@
|
|||
<span class="component-title">Update shows on startup</span>
|
||||
<span class="component-desc">
|
||||
<input type="checkbox" name="update_shows_on_start" id="update_shows_on_start"#echo ('', $checked)[$sickbeard.UPDATE_SHOWS_ON_START]#>
|
||||
<p>with show data; episode plot, images, air and end dates, etc. Disable for a quicker startup. Show data is scheduled to update during hour <span class="show_update_hour_value">$sickbeard.SHOW_UPDATE_HOUR</span>.</p>
|
||||
<p>with show data; episode plot, images, air and end dates, etc. Disable for a quicker startup. Show data is scheduled to update during hour <span class="show_update_hour_value">$sickbeard.SHOW_UPDATE_HOUR</span></p>
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
|
@ -86,7 +86,19 @@
|
|||
</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
|
||||
#if hasattr($sickbeard, 'ALLOW_INCOMPLETE_SHOWDATA')
|
||||
<div class="field-pair">
|
||||
<label for="allow_incomplete_showdata">
|
||||
<span class="component-title">Allow incomplete show data</span>
|
||||
<span class="component-desc">
|
||||
<input type="checkbox" name="allow_incomplete_showdata" id="allow_incomplete_showdata"#echo ('', $checked)[$sickbeard.ALLOW_INCOMPLETE_SHOWDATA]#>
|
||||
<p>add partial show data for future updates to complete</p>
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
#end if
|
||||
|
||||
<div class="field-pair">
|
||||
<span class="component-title">Send to trash for actions</span>
|
||||
<span class="component-desc">
|
||||
|
|
|
@ -116,7 +116,7 @@
|
|||
#end if
|
||||
<div id="details-wrapper">
|
||||
<div id="details-right">
|
||||
#if $seasonResults
|
||||
#if 0 < len($seasonResults)
|
||||
##There is a special/season_0?##
|
||||
#set $season_special = (0, 1)[0 == int($seasonResults[-1]['season'])]
|
||||
##
|
||||
|
@ -397,7 +397,11 @@
|
|||
#end if
|
||||
##
|
||||
#if 0 == len($sqlResults)
|
||||
<div style="margin-top:50px"><h3>Episodes no longer exist for this show at the associated indexer</h3></div>
|
||||
<div style="margin-top:50px">
|
||||
<h3>Episodes do not exist for this show at the associated indexer
|
||||
<a class="service" href="<%= anon_url(sickbeard.indexerApi(_show.indexer).config['show_url'], _show.indexerid) %>" onclick="window.open(this.href, '_blank'); return false;" title="Show $sickbeard.indexerApi($show.indexer).name info in new tab">$sickbeard.indexerApi($show.indexer).name</a>
|
||||
</h3>
|
||||
</div>
|
||||
#else:
|
||||
#for $epResult in $sqlResults
|
||||
#set $epStr = '%sx%s' % ($epResult['season'], $epResult['episode'])
|
||||
|
@ -518,7 +522,7 @@
|
|||
<td class="col-name">
|
||||
<img src="$sbRoot/images/info32.png" width="16" height="16" alt="" class="plotInfo#echo '%s" />' %\
|
||||
('None', ('" id="plot_info_%s_%s_%s' % ($show.indexerid, $epResult['season'], $epResult['episode'])))[None is not $epResult['description'] and '' != $epResult['description']]#
|
||||
$epResult['name']
|
||||
<%= '<em class="tba grey-text">TBA</em>' if not epResult['name'] or 'TBA' == epResult['name'] else epResult['name'] %>
|
||||
</td>
|
||||
|
||||
<td class="col-airdate">
|
||||
|
|
|
@ -84,6 +84,7 @@ traktCheckerScheduler = None
|
|||
showList = None
|
||||
UPDATE_SHOWS_ON_START = False
|
||||
SHOW_UPDATE_HOUR = 3
|
||||
ALLOW_INCOMPLETE_SHOWDATA = False
|
||||
|
||||
providerList = []
|
||||
newznabProviderList = []
|
||||
|
@ -474,7 +475,7 @@ def initialize(consoleLogging=True):
|
|||
USE_TRAKT, TRAKT_USERNAME, TRAKT_PASSWORD, TRAKT_API, TRAKT_REMOVE_WATCHLIST, TRAKT_USE_WATCHLIST, TRAKT_METHOD_ADD, TRAKT_START_PAUSED, traktCheckerScheduler, TRAKT_USE_RECOMMENDED, TRAKT_SYNC, TRAKT_DEFAULT_INDEXER, TRAKT_REMOVE_SERIESLIST, \
|
||||
USE_PLEX, PLEX_NOTIFY_ONSNATCH, PLEX_NOTIFY_ONDOWNLOAD, PLEX_NOTIFY_ONSUBTITLEDOWNLOAD, PLEX_UPDATE_LIBRARY, \
|
||||
PLEX_SERVER_HOST, PLEX_HOST, PLEX_USERNAME, PLEX_PASSWORD, DEFAULT_BACKLOG_FREQUENCY, MIN_BACKLOG_FREQUENCY, MAX_BACKLOG_FREQUENCY, BACKLOG_STARTUP, SKIP_REMOVED_FILES, \
|
||||
showUpdateScheduler, __INITIALIZED__, LAUNCH_BROWSER, TRASH_REMOVE_SHOW, TRASH_ROTATE_LOGS, HOME_SEARCH_FOCUS, SORT_ARTICLE, showList, loadingShowList, UPDATE_SHOWS_ON_START, SHOW_UPDATE_HOUR, \
|
||||
showUpdateScheduler, __INITIALIZED__, LAUNCH_BROWSER, TRASH_REMOVE_SHOW, TRASH_ROTATE_LOGS, HOME_SEARCH_FOCUS, SORT_ARTICLE, showList, loadingShowList, UPDATE_SHOWS_ON_START, SHOW_UPDATE_HOUR, ALLOW_INCOMPLETE_SHOWDATA, \
|
||||
NEWZNAB_DATA, INDEXER_DEFAULT, INDEXER_TIMEOUT, USENET_RETENTION, TORRENT_DIR, \
|
||||
QUALITY_DEFAULT, FLATTEN_FOLDERS_DEFAULT, SUBTITLES_DEFAULT, STATUS_DEFAULT, WANTED_BEGIN_DEFAULT, WANTED_LATEST_DEFAULT, RECENTSEARCH_STARTUP, \
|
||||
GROWL_NOTIFY_ONSNATCH, GROWL_NOTIFY_ONDOWNLOAD, GROWL_NOTIFY_ONSUBTITLEDOWNLOAD, TWITTER_NOTIFY_ONSNATCH, TWITTER_NOTIFY_ONDOWNLOAD, TWITTER_NOTIFY_ONSUBTITLEDOWNLOAD, \
|
||||
|
@ -624,6 +625,8 @@ def initialize(consoleLogging=True):
|
|||
UPDATE_SHOWS_ON_START = bool(check_setting_int(CFG, 'General', 'update_shows_on_start', 0))
|
||||
SHOW_UPDATE_HOUR = check_setting_int(CFG, 'General', 'show_update_hour', 3)
|
||||
SHOW_UPDATE_HOUR = minimax(SHOW_UPDATE_HOUR, 3, 0, 23)
|
||||
ALLOW_INCOMPLETE_SHOWDATA = bool(check_setting_int(CFG, 'General', 'allow_incomplete_showdata', 0))
|
||||
|
||||
TRASH_REMOVE_SHOW = bool(check_setting_int(CFG, 'General', 'trash_remove_show', 0))
|
||||
TRASH_ROTATE_LOGS = bool(check_setting_int(CFG, 'General', 'trash_rotate_logs', 0))
|
||||
|
||||
|
@ -1418,6 +1421,7 @@ def save_config():
|
|||
new_config['General']['launch_browser'] = int(LAUNCH_BROWSER)
|
||||
new_config['General']['update_shows_on_start'] = int(UPDATE_SHOWS_ON_START)
|
||||
new_config['General']['show_update_hour'] = int(SHOW_UPDATE_HOUR)
|
||||
new_config['General']['allow_incomplete_showdata'] = int(ALLOW_INCOMPLETE_SHOWDATA)
|
||||
new_config['General']['trash_remove_show'] = int(TRASH_REMOVE_SHOW)
|
||||
new_config['General']['trash_rotate_logs'] = int(TRASH_ROTATE_LOGS)
|
||||
new_config['General']['home_search_focus'] = int(HOME_SEARCH_FOCUS)
|
||||
|
|
|
@ -301,12 +301,11 @@ class QueueItemAdd(ShowQueueItem):
|
|||
self._finishEarly()
|
||||
return
|
||||
# if the show has no episodes/seasons
|
||||
if not s:
|
||||
logger.log(u'Show ' + str(s['seriesname']) + ' is on ' + str(
|
||||
sickbeard.indexerApi(self.indexer).name) + ' but contains no season/episode data.', logger.ERROR)
|
||||
ui.notifications.error('Unable to add show',
|
||||
'Show ' + str(s['seriesname']) + ' is on ' + str(sickbeard.indexerApi(
|
||||
self.indexer).name) + ' but contains no season/episode data.')
|
||||
if not sickbeard.ALLOW_INCOMPLETE_SHOWDATA and not s:
|
||||
msg = u'Show %s is on %s but contains no season/episode data. Only the show folder was created.'\
|
||||
% (s['seriesname'], sickbeard.indexerApi(self.indexer).name)
|
||||
logger.log(msg, logger.ERROR)
|
||||
ui.notifications.error('Unable to add show', msg)
|
||||
self._finishEarly()
|
||||
return
|
||||
except Exception as e:
|
||||
|
|
|
@ -1698,7 +1698,7 @@ class TVEpisode(object):
|
|||
self.deleteEpisode()
|
||||
return
|
||||
|
||||
if getattr(myEp, 'episodename', None) is None:
|
||||
if not sickbeard.ALLOW_INCOMPLETE_SHOWDATA and getattr(myEp, 'episodename', None) is None:
|
||||
logger.log(u"This episode (" + self.show.name + " - " + str(season) + "x" + str(
|
||||
episode) + ") has no name on " + sickbeard.indexerApi(self.indexer).name + "")
|
||||
# if I'm incomplete on TVDB but I once was complete then just delete myself from the DB for now
|
||||
|
|
|
@ -3439,7 +3439,8 @@ class ConfigGeneral(Config):
|
|||
return m.hexdigest()
|
||||
|
||||
def saveGeneral(self, log_dir=None, web_port=None, web_log=None, encryption_version=None, web_ipv6=None,
|
||||
update_shows_on_start=None, show_update_hour=None, trash_remove_show=None, trash_rotate_logs=None, update_frequency=None, launch_browser=None, web_username=None,
|
||||
update_shows_on_start=None, show_update_hour=None, allow_incomplete_showdata=None,
|
||||
trash_remove_show=None, trash_rotate_logs=None, update_frequency=None, launch_browser=None, web_username=None,
|
||||
use_api=None, api_key=None, indexer_default=None, timezone_display=None, cpu_preset=None, file_logging_preset=None,
|
||||
web_password=None, version_notify=None, enable_https=None, https_cert=None, https_key=None,
|
||||
handle_reverse_proxy=None, home_search_focus=None, sort_article=None, auto_update=None, notify_on_update=None,
|
||||
|
@ -3460,6 +3461,7 @@ class ConfigGeneral(Config):
|
|||
|
||||
sickbeard.UPDATE_SHOWS_ON_START = config.checkbox_to_value(update_shows_on_start)
|
||||
sickbeard.SHOW_UPDATE_HOUR = config.minimax(show_update_hour, 3, 0, 23)
|
||||
sickbeard.ALLOW_INCOMPLETE_SHOWDATA = config.checkbox_to_value(allow_incomplete_showdata)
|
||||
sickbeard.TRASH_REMOVE_SHOW = config.checkbox_to_value(trash_remove_show)
|
||||
sickbeard.TRASH_ROTATE_LOGS = config.checkbox_to_value(trash_rotate_logs)
|
||||
config.change_UPDATE_FREQUENCY(update_frequency)
|
||||
|
|
Loading…
Reference in a new issue