You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1914 lines
86 KiB

# Author: Nic Wolfe <nic@wolfeden.ca>
# URL: http://code.google.com/p/sickbeard/
#
# This file is part of SickGear.
#
# SickGear is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# SickGear is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with SickGear. If not, see <http://www.gnu.org/licenses/>.
import datetime
import os.path
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
from .. import db, common, logger
from ..name_parser.parser import NameParser, InvalidNameException, InvalidShowException
import sickbeard
# noinspection PyPep8Naming
import encodingKludge as ek
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
from six import iteritems
MIN_DB_VERSION = 9 # oldest db version we support migrating from
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
MAX_DB_VERSION = 100008
TEST_BASE_VERSION = 20014 # the base production db version, only needed for TEST db versions (>=100000)
class MainSanityCheck(db.DBSanityCheck):
def check(self):
self.fix_missing_table_indexes()
self.fix_duplicate_shows()
self.fix_duplicate_episodes()
self.fix_orphan_episodes()
self.fix_unaired_episodes()
self.fix_scene_exceptions()
self.fix_orphan_not_found_show()
self.fix_fallback_mapping()
self.fix_indexer_mapping_tvdb()
def fix_indexer_mapping_tvdb(self):
if not self.connection.has_flag('fix_indexer_mapping_tvdb'):
self.connection.action('DELETE FROM indexer_mapping WHERE mindexer = ?', [10001])
self.connection.set_flag('fix_indexer_mapping_tvdb')
def fix_duplicate_shows(self, column='indexer_id'):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# This func would break with multi tv info sources and without tvid, so added check min db version to mitigate
# Also, tv_show table had a unique index added at some time to prevent further dupes,
# therefore, this func is kept to cleanse legacy data given that it's redundant for new row insertions
if self.connection.checkDBVersion() < 20004:
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
sql_result = self.connection.select(
'SELECT show_id, %(col)s, COUNT(%(col)s) AS count FROM tv_shows GROUP BY %(col)s HAVING count > 1'
% {'col': column})
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
for cur_result in sql_result:
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
logger.log(u'Duplicate show detected! %s: %s count: %s' % (
column, cur_result[column], cur_result['count']), logger.DEBUG)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
cur_dupe_results = self.connection.select(
'SELECT show_id, ' + column + ' FROM tv_shows WHERE ' + column + ' = ? LIMIT ?',
[cur_result[column], int(cur_result['count']) - 1]
)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
cl = []
for cur_dupe_id in cur_dupe_results:
logger.log(u'Deleting duplicate show with %s: %s show_id: %s' % (
column, cur_dupe_id[column], cur_dupe_id['show_id']))
cl.append(['DELETE FROM tv_shows WHERE show_id = ?', [cur_dupe_id['show_id']]])
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if 0 < len(cl):
self.connection.mass_action(cl)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
else:
logger.log(u'No duplicate show, check passed')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
def fix_duplicate_episodes(self):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# This func would break with multi tv info sources and without tvid, so added check min db version to mitigate
# Also, tv_show table had a unique index added at some time to prevent further dupes,
# therefore, this func is kept to cleanse legacy data given that it's redundant for new row insertions
if self.connection.checkDBVersion() < 20007:
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
sql_result = self.connection.select(
'SELECT indexer AS tv_id, showid AS prod_id, season, episode, COUNT(showid) as count'
' FROM tv_episodes'
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
' GROUP BY tv_id, prod_id, season, episode'
' HAVING count > 1')
for cur_result in sql_result:
logger.log(u'Duplicate episode detected! prod_id: %s season: %s episode: %s count: %s' %
(cur_result['prod_id'], cur_result['season'], cur_result['episode'],
cur_result['count']), logger.DEBUG)
cur_dupe_results = self.connection.select(
'SELECT episode_id'
' FROM tv_episodes'
' WHERE indexer = ? AND showid = ?'
' AND season = ? AND episode = ?'
' ORDER BY episode_id DESC LIMIT ?',
[cur_result['tv_id'], cur_result['prod_id'],
cur_result['season'], cur_result['episode'],
int(cur_result['count']) - 1]
)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
cl = []
for cur_dupe_id in cur_dupe_results:
logger.log(u'Deleting duplicate episode with episode_id: %s' % cur_dupe_id['episode_id'])
cl.append(['DELETE FROM tv_episodes WHERE episode_id = ?', [cur_dupe_id['episode_id']]])
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if 0 < len(cl):
self.connection.mass_action(cl)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
else:
logger.log(u'No duplicate episode, check passed')
def fix_orphan_episodes(self):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
sql_result = self.connection.select(
'SELECT episode_id, showid, tv_shows.indexer_id'
' FROM tv_episodes'
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
' LEFT JOIN tv_shows ON tv_episodes.showid=tv_shows.indexer_id AND tv_episodes.indexer=tv_shows.indexer '
' WHERE tv_shows.indexer_id is NULL')
cl = []
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
for cur_result in sql_result:
logger.log(u'Orphan episode detected! episode_id: %s showid: %s' % (
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
cur_result['episode_id'], cur_result['showid']), logger.DEBUG)
logger.log(u'Deleting orphan episode with episode_id: %s' % cur_result['episode_id'])
cl.append(['DELETE FROM tv_episodes WHERE episode_id = ?', [cur_result['episode_id']]])
if 0 < len(cl):
self.connection.mass_action(cl)
else:
logger.log(u'No orphan episodes, check passed')
def fix_missing_table_indexes(self):
if not self.connection.select('PRAGMA index_info("idx_indexer_id")'):
logger.log('Updating TV Shows table with index idx_indexer_id')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.connection.action('CREATE UNIQUE INDEX idx_indexer_id ON tv_shows (indexer, indexer_id);')
if not self.connection.select('PRAGMA index_info("idx_tv_episodes_showid_airdate")'):
logger.log('Updating TV Episode table with index idx_tv_episodes_showid_airdate')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.connection.action('CREATE INDEX idx_tv_episodes_showid_airdate'
' ON tv_episodes(indexer,showid,airdate);')
if not self.connection.select('PRAGMA index_info("idx_status")'):
logger.log('Updating TV Episode table with index idx_status')
self.connection.action('CREATE INDEX idx_status ON tv_episodes (status, season, episode, airdate)')
if not self.connection.select('PRAGMA index_info("idx_sta_epi_air")'):
logger.log('Updating TV Episode table with index idx_sta_epi_air')
self.connection.action('CREATE INDEX idx_sta_epi_air ON tv_episodes (status, episode, airdate)')
if not self.connection.select('PRAGMA index_info("idx_sta_epi_sta_air")'):
logger.log('Updating TV Episode table with index idx_sta_epi_sta_air')
self.connection.action('CREATE INDEX idx_sta_epi_sta_air ON tv_episodes (season, episode, status, airdate)')
if not self.connection.hasIndex('tv_episodes', 'idx_tv_ep_ids'):
logger.log('Updating TV Episode table with index idx_tv_ep_ids')
self.connection.action('CREATE INDEX idx_tv_ep_ids ON tv_episodes (indexer, showid)')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if not self.connection.hasIndex('tv_episodes', 'idx_tv_episodes_unique'):
self.connection.action('CREATE UNIQUE INDEX idx_tv_episodes_unique ON '
'tv_episodes(indexer,showid,season,episode)')
allowtbl, blocktbl = (('allow', 'block'), ('white', 'black'))[not self.connection.hasTable('blocklist')]
for t in [('%slist' % allowtbl, 'show_id'), ('%slist' % blocktbl, 'show_id'),
('history', 'showid'), ('scene_exceptions', 'indexer_id')]:
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if not self.connection.hasIndex('%s' % t[0], 'idx_id_indexer_%s' % t[0]):
# noinspection SqlResolve
self.connection.action('CREATE INDEX idx_id_indexer_%s ON %s (indexer, %s)' % (t[0], t[0], t[1]))
def fix_unaired_episodes(self):
cur_date = datetime.date.today() + datetime.timedelta(days=1)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
sql_result = self.connection.select(
'SELECT episode_id, showid FROM tv_episodes WHERE status = ? or ( airdate > ? AND status in (?,?) ) or '
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
'( airdate <= 1 AND status = ? )', ['', cur_date.toordinal(), common.SKIPPED, common.WANTED, common.WANTED])
cl = []
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
for cur_result in sql_result:
logger.log(u'UNAIRED episode detected! episode_id: %s showid: %s' % (
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
cur_result['episode_id'], cur_result['showid']), logger.DEBUG)
logger.log(u'Fixing unaired episode status with episode_id: %s' % cur_result['episode_id'])
cl.append(['UPDATE tv_episodes SET status = ? WHERE episode_id = ?',
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
[common.UNAIRED, cur_result['episode_id']]])
if 0 < len(cl):
self.connection.mass_action(cl)
else:
logger.log(u'No UNAIRED episodes, check passed')
def fix_scene_exceptions(self):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
sql_result = self.connection.select(
'SELECT exception_id FROM scene_exceptions WHERE season = "null"')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if 0 < len(sql_result):
logger.log('Fixing invalid scene exceptions')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('UPDATE scene_exceptions SET season = -1 WHERE season = "null"')
def fix_orphan_not_found_show(self):
sql_result = self.connection.action(
'DELETE FROM tv_shows_not_found'
' WHERE NOT EXISTS (SELECT NULL FROM tv_shows WHERE tv_shows_not_found.indexer == tv_shows.indexer AND'
' tv_shows_not_found.indexer_id == tv_shows.indexer_id)')
if sql_result.rowcount:
logger.log('Fixed orphaned not found shows')
def fix_fallback_mapping(self):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
fallback_indexer = [i for i in sickbeard.TVInfoAPI().fallback_sources]
if fallback_indexer:
sql_result = self.connection.action(
'DELETE FROM indexer_mapping WHERE mindexer IN (%s) OR indexer in (%s)' %
(','.join(['?'] * len(fallback_indexer)), ','.join(['?'] * len(fallback_indexer))),
fallback_indexer + fallback_indexer)
if sql_result.rowcount:
logger.log('Fixed fallback indexer mappings')
class InitialSchema(db.SchemaUpgrade):
# ======================
# = Main DB Migrations =
# ======================
# Add new migrations at the bottom of the list; subclass the previous migration.
# 0 -> 20009
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
if not self.hasTable('tv_shows') and not self.hasTable('db_version'):
queries = [
# anime allow and block list
'CREATE TABLE allowlist (show_id INTEGER, range TEXT, keyword TEXT, indexer NUMERIC)',
'CREATE TABLE blocklist (show_id INTEGER, range TEXT, keyword TEXT, indexer NUMERIC)',
# db_version
'CREATE TABLE db_version (db_version INTEGER)',
'INSERT INTO db_version (db_version) VALUES (20008)',
# flags
'CREATE TABLE flags (flag PRIMARY KEY NOT NULL)',
# history
'CREATE TABLE history (action NUMERIC, date NUMERIC, showid NUMERIC, season NUMERIC, episode NUMERIC,'
' quality NUMERIC, resource TEXT, provider TEXT, version NUMERIC, hide NUMERIC DEFAULT 0)',
# imdb_info
'CREATE TABLE imdb_info (indexer_id INTEGER PRIMARY KEY, imdb_id TEXT, title TEXT, year NUMERIC,'
' akas TEXT, runtimes NUMERIC, genres TEXT, countries TEXT, country_codes TEXT, certificates TEXT,'
' rating TEXT, votes INTEGER, last_update NUMERIC)',
# indexer_mapping
'CREATE TABLE indexer_mapping (indexer_id INTEGER, indexer NUMERIC, mindexer_id INTEGER NOT NULL,'
' mindexer NUMERIC, date NUMERIC NOT NULL DEFAULT 0, status INTEGER NOT NULL DEFAULT 0,'
' PRIMARY KEY (indexer_id, indexer, mindexer))',
'CREATE INDEX idx_mapping ON indexer_mapping (indexer_id, indexer)',
# info
'CREATE TABLE info (last_backlog NUMERIC, last_indexer NUMERIC, last_proper_search NUMERIC,'
' last_run_backlog NUMERIC NOT NULL DEFAULT 1)',
# scene_exceptions
'CREATE TABLE scene_exceptions (exception_id INTEGER PRIMARY KEY, indexer_id INTEGER KEY,'
' show_name TEXT, season NUMERIC, custom NUMERIC)',
# scene_exceptions_refresh
'CREATE TABLE scene_exceptions_refresh (list TEXT PRIMARY KEY, last_refreshed INTEGER)',
# scene_numbering
'CREATE TABLE scene_numbering (indexer TEXT, indexer_id INTEGER, season INTEGER, episode INTEGER,'
' scene_season INTEGER, scene_episode INTEGER, absolute_number NUMERIC, scene_absolute_number NUMERIC,'
' PRIMARY KEY (indexer_id, season, episode))',
# tv_episodes
'CREATE TABLE tv_episodes (episode_id INTEGER PRIMARY KEY, showid NUMERIC, indexerid NUMERIC,'
' indexer NUMERIC, name TEXT, season NUMERIC, episode NUMERIC, description TEXT, airdate NUMERIC,'
' hasnfo NUMERIC, hastbn NUMERIC, status NUMERIC, location TEXT, file_size NUMERIC, release_name TEXT,'
' subtitles TEXT, subtitles_searchcount NUMERIC, subtitles_lastsearch TIMESTAMP, is_proper NUMERIC,'
' scene_season NUMERIC, scene_episode NUMERIC, absolute_number NUMERIC, scene_absolute_number NUMERIC,'
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
' version NUMERIC, release_group TEXT)',
'CREATE INDEX idx_showid ON tv_episodes (showid)',
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
'CREATE INDEX idx_tv_episodes_showid_airdate ON tv_episodes (showid,airdate)',
'CREATE INDEX idx_sta_epi_air ON tv_episodes (status,episode, airdate)',
'CREATE INDEX idx_sta_epi_sta_air ON tv_episodes (season,episode, status, airdate)',
'CREATE INDEX idx_status ON tv_episodes (status,season,episode,airdate)',
# tv_episodes_watched
'CREATE TABLE tv_episodes_watched (tvep_id NUMERIC NOT NULL, clientep_id TEXT, label TEXT,'
' played NUMERIC NOT NULL DEFAULT 0, date_watched NUMERIC NOT NULL, date_added NUMERIC,'
' status NUMERIC, location TEXT, file_size NUMERIC, hide INT NOT NULL DEFAULT 0)',
# tv_shows
'CREATE TABLE tv_shows (show_id INTEGER PRIMARY KEY, indexer_id NUMERIC, indexer NUMERIC,'
' show_name TEXT, location TEXT, network TEXT, genre TEXT, classification TEXT, runtime NUMERIC,'
' quality NUMERIC, airs TEXT, status TEXT, flatten_folders NUMERIC, paused NUMERIC, startyear NUMERIC,'
' air_by_date NUMERIC, lang TEXT, subtitles NUMERIC, notify_list TEXT, imdb_id TEXT,'
' last_update_indexer NUMERIC, dvdorder NUMERIC, archive_firstmatch NUMERIC, rls_require_words TEXT,'
' rls_ignore_words TEXT, sports NUMERIC, anime NUMERIC, scene NUMERIC, overview TEXT, tag TEXT,'
' prune INT DEFAULT 0)',
'CREATE UNIQUE INDEX idx_indexer_id ON tv_shows (indexer_id)',
# tv_shows_not_found
'CREATE TABLE tv_shows_not_found (indexer NUMERIC NOT NULL, indexer_id NUMERIC NOT NULL,'
' fail_count NUMERIC NOT NULL DEFAULT 0, last_check NUMERIC NOT NULL, last_success NUMERIC,'
' PRIMARY KEY (indexer_id, indexer))',
# webdl_types
'CREATE TABLE webdl_types (dname TEXT NOT NULL, regex TEXT NOT NULL)',
# xem_refresh
'CREATE TABLE xem_refresh (indexer TEXT, indexer_id INTEGER PRIMARY KEY, last_refreshed INTEGER)',
]
for query in queries:
self.connection.action(query)
else:
cur_db_version = self.checkDBVersion()
if cur_db_version < MIN_DB_VERSION:
logger.log_error_and_exit(
u'Your database version (' + str(cur_db_version)
+ ') is too old to migrate from what this version of SickGear supports ('
+ str(MIN_DB_VERSION) + ').' + "\n"
+ 'Upgrade using a previous version (tag) build 496 to build 501 of SickGear'
' first or remove database file to begin fresh.'
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
)
if cur_db_version > MAX_DB_VERSION:
logger.log_error_and_exit(
u'Your database version (' + str(cur_db_version)
+ ') has been incremented past what this version of SickGear supports ('
+ str(MAX_DB_VERSION) + ').\n'
+ 'If you have used other forks of SickGear,'
' your database may be unusable due to their modifications.'
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
)
return self.checkDBVersion()
# 9 -> 10
class AddSizeAndSceneNameFields(db.SchemaUpgrade):
def execute(self):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
"""
This func is only for 9->10 where older db columns exist,
those columns have since changed
"""
db.backup_database('sickbeard.db', self.checkDBVersion())
if not self.hasColumn('tv_episodes', 'file_size'):
self.addColumn('tv_episodes', 'file_size')
if not self.hasColumn('tv_episodes', 'release_name'):
self.addColumn('tv_episodes', 'release_name', 'TEXT', '')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
sql_result = self.connection.select('SELECT episode_id, location, file_size FROM tv_episodes')
self.upgrade_log(u'Adding file size to all episodes in DB, please be patient')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
for cur_result in sql_result:
if not cur_result['location']:
continue
# if there is no size yet then populate it for us
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if (not cur_result['file_size'] or not int(cur_result['file_size'])) \
and ek.ek(os.path.isfile, cur_result['location']):
cur_size = ek.ek(os.path.getsize, cur_result['location'])
self.connection.action('UPDATE tv_episodes SET file_size = ? WHERE episode_id = ?',
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
[cur_size, int(cur_result['episode_id'])])
# check each snatch to see if we can use it to get a release name from
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlRedundantOrderingDirection
history_sql_result = self.connection.select('SELECT * FROM history WHERE provider != -1 ORDER BY date ASC')
self.upgrade_log(u'Adding release name to all episodes still in history')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
for cur_result in history_sql_result:
# find the associated download, if there isn't one then ignore it
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
download_sql_result = self.connection.select(
'SELECT resource'
' FROM history'
' WHERE provider = -1 AND showid = ? AND season = ? AND episode = ? AND date > ?',
[cur_result['showid'], cur_result['season'], cur_result['episode'], cur_result['date']])
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if not download_sql_result:
self.upgrade_log(u'Found a snatch in the history for ' + cur_result['resource']
+ ' but couldn\'t find the associated download, skipping it', logger.DEBUG)
continue
nzb_name = cur_result['resource']
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
file_name = ek.ek(os.path.basename, download_sql_result[0]['resource'])
# take the extension off the filename, it's not needed
if '.' in file_name:
file_name = file_name.rpartition('.')[0]
# find the associated episode on disk
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
sql_result = self.connection.select(
'SELECT episode_id, status'
' FROM tv_episodes'
' WHERE showid = ? AND season = ? AND episode = ? AND location != ""',
[cur_result['showid'], cur_result['season'], cur_result['episode']])
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if not sql_result:
logger.log(
u'The episode ' + nzb_name + ' was found in history but doesn\'t exist on disk anymore, skipping',
logger.DEBUG)
continue
# get the status/quality of the existing ep and make sure it's what we expect
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
ep_status, ep_quality = common.Quality.splitCompositeStatus(int(sql_result[0]['status']))
if ep_status != common.DOWNLOADED:
continue
if ep_quality != int(cur_result['quality']):
continue
# make sure this is actually a real release name and not a season pack or something
for cur_name in (nzb_name, file_name):
logger.log(u'Checking if ' + cur_name + ' is actually a good release name', logger.DEBUG)
try:
np = NameParser(False)
parse_result = np.parse(cur_name)
except (InvalidNameException, InvalidShowException):
continue
if parse_result.series_name and parse_result.season_number is not None\
and parse_result.episode_numbers and parse_result.release_group:
# if all is well by this point we'll just put the release name into the database
self.connection.action('UPDATE tv_episodes SET release_name = ? WHERE episode_id = ?',
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
[cur_name, sql_result[0]['episode_id']])
break
# check each snatch to see if we can use it to get a release name from
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
empty_sql_result = self.connection.select('SELECT episode_id, location'
' FROM tv_episodes'
' WHERE release_name = ""')
self.upgrade_log(u'Adding release name to all episodes with obvious scene filenames')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
for cur_result in empty_sql_result:
ep_file_name = ek.ek(os.path.basename, cur_result['location'])
ep_file_name = os.path.splitext(ep_file_name)[0]
# only want to find real scene names here so anything with a space in it is out
if ' ' in ep_file_name:
continue
try:
np = NameParser(False)
parse_result = np.parse(ep_file_name)
except (InvalidNameException, InvalidShowException):
continue
if not parse_result.release_group:
continue
logger.log(
u'Name ' + ep_file_name + ' gave release group of ' + parse_result.release_group + ', seems valid',
logger.DEBUG)
self.connection.action('UPDATE tv_episodes SET release_name = ? WHERE episode_id = ?',
[ep_file_name, cur_result['episode_id']])
self.incDBVersion()
return self.checkDBVersion()
# 10 -> 11
class RenameSeasonFolders(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
# rename the column
self.connection.action('ALTER TABLE tv_shows RENAME TO tmp_tv_shows')
self.connection.action(
'CREATE TABLE tv_shows (show_id INTEGER PRIMARY KEY, location TEXT, show_name TEXT, tvdb_id NUMERIC,'
' network TEXT, genre TEXT, runtime NUMERIC, quality NUMERIC, airs TEXT, status TEXT,'
' flatten_folders NUMERIC, paused NUMERIC, startyear NUMERIC, tvr_id NUMERIC, tvr_name TEXT,'
' air_by_date NUMERIC, lang TEXT)')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
sql = 'INSERT INTO tv_shows(show_id, location, show_name, tvdb_id, network, genre, runtime,' \
' quality, airs, status, flatten_folders, paused, startyear, tvr_id, tvr_name, air_by_date, lang)' \
' SELECT show_id, location, show_name, tvdb_id, network, genre, runtime, quality, airs, status,' \
' seasonfolders, paused, startyear, tvr_id, tvr_name, air_by_date, lang FROM tmp_tv_shows'
self.connection.action(sql)
# flip the values to be opposite of what they were before
self.connection.action('UPDATE tv_shows SET flatten_folders = 2 WHERE flatten_folders = 1')
self.connection.action('UPDATE tv_shows SET flatten_folders = 1 WHERE flatten_folders = 0')
self.connection.action('UPDATE tv_shows SET flatten_folders = 0 WHERE flatten_folders = 2')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_tv_shows')
self.incDBVersion()
return self.checkDBVersion()
# 11 -> 12
class Add1080pAndRawHDQualities(db.SchemaUpgrade):
"""
Add support for 1080p related qualities along with RawHD
Quick overview of what the upgrade needs to do:
quality | old | new
--------------------------
hdwebdl | 1<<3 | 1<<5
hdbluray | 1<<4 | 1<<7
fullhdbluray | 1<<5 | 1<<8
--------------------------
rawhdtv | | 1<<3
fullhdtv | | 1<<4
fullhdwebdl | | 1<<6
"""
def _update_status(self, old_status):
(status, quality) = common.Quality.splitCompositeStatus(old_status)
return common.Quality.compositeStatus(status, self._update_quality(quality))
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
@staticmethod
def _update_quality(old_quality):
"""
Update bitwise flags to reflect new quality values
Check flag bits (clear old then set their new locations) starting
with the highest bits so we dont overwrite data we need later on
"""
result = old_quality
# move fullhdbluray from 1<<5 to 1<<8 if set
if result & (1 << 5):
result &= ~(1 << 5)
result |= 1 << 8
# move hdbluray from 1<<4 to 1<<7 if set
if result & (1 << 4):
result &= ~(1 << 4)
result |= 1 << 7
# move hdwebdl from 1<<3 to 1<<5 if set
if result & (1 << 3):
result &= ~(1 << 3)
result |= 1 << 5
return result
def _update_composite_qualities(self, status):
"""
Unpack, Update, Return new quality values
Unpack the composite archive/initial values.
Update either qualities if needed.
Then return the new compsite quality value.
"""
best = (status & (0xffff << 16)) >> 16
initial = status & 0xffff
best = self._update_quality(best)
initial = self._update_quality(initial)
result = ((best << 16) | initial)
return result
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
# update the default quality so we dont grab the wrong qualities after migration
sickbeard.QUALITY_DEFAULT = self._update_composite_qualities(sickbeard.QUALITY_DEFAULT)
sickbeard.save_config()
# upgrade previous HD to HD720p -- shift previous qualities to new placevalues
old_hd = common.Quality.combineQualities(
[common.Quality.HDTV, common.Quality.HDWEBDL >> 2, common.Quality.HDBLURAY >> 3], [])
new_hd = common.Quality.combineQualities([common.Quality.HDTV, common.Quality.HDWEBDL,
common.Quality.HDBLURAY], [])
# update ANY -- shift existing qualities and add new 1080p qualities,
# note that rawHD was not added to the ANY template
old_any = common.Quality.combineQualities(
[common.Quality.SDTV, common.Quality.SDDVD, common.Quality.HDTV, common.Quality.HDWEBDL >> 2,
common.Quality.HDBLURAY >> 3, common.Quality.UNKNOWN], [])
new_any = common.Quality.combineQualities(
[common.Quality.SDTV, common.Quality.SDDVD, common.Quality.HDTV, common.Quality.FULLHDTV,
common.Quality.HDWEBDL, common.Quality.FULLHDWEBDL, common.Quality.HDBLURAY, common.Quality.FULLHDBLURAY,
common.Quality.UNKNOWN], [])
# update qualities (including templates)
self.upgrade_log(u'[1/4] Updating pre-defined templates and the quality for each show...')
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
cl = []
shows = self.connection.select('SELECT * FROM tv_shows')
for cur_show in shows:
if old_hd == cur_show['quality']:
new_quality = new_hd
elif old_any == cur_show['quality']:
new_quality = new_any
else:
new_quality = self._update_composite_qualities(cur_show['quality'])
cl.append(['UPDATE tv_shows SET quality = ? WHERE show_id = ?', [new_quality, cur_show['show_id']]])
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
self.connection.mass_action(cl)
# update status that are are within the old hdwebdl
# (1<<3 which is 8) and better -- exclude unknown (1<<15 which is 32768)
self.upgrade_log(u'[2/4] Updating the status for the episodes within each show...')
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
cl = []
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
sql_result = self.connection.select('SELECT * FROM tv_episodes WHERE status < 3276800 AND status >= 800')
for cur_result in sql_result:
cl.append(['UPDATE tv_episodes SET status = ? WHERE episode_id = ?',
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
[self._update_status(cur_result['status']), cur_result['episode_id']]])
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
self.connection.mass_action(cl)
# make two seperate passes through the history since snatched and downloaded (action & quality)
# may not always coordinate together
# update previous history so it shows the correct action
self.upgrade_log(u'[3/4] Updating history to reflect the correct action...')
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
cl = []
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
history_action = self.connection.select('SELECT * FROM history WHERE action < 3276800 AND action >= 800')
for cur_entry in history_action:
cl.append(['UPDATE history SET action = ? WHERE showid = ? AND date = ?',
[self._update_status(cur_entry['action']), cur_entry['showid'], cur_entry['date']]])
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
self.connection.mass_action(cl)
# update previous history so it shows the correct quality
self.upgrade_log(u'[4/4] Updating history to reflect the correct quality...')
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
cl = []
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
history_quality = self.connection.select('SELECT * FROM history WHERE quality < 32768 AND quality >= 8')
for cur_entry in history_quality:
cl.append(['UPDATE history SET quality = ? WHERE showid = ? AND date = ?',
[self._update_quality(cur_entry['quality']), cur_entry['showid'], cur_entry['date']]])
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
self.connection.mass_action(cl)
self.incDBVersion()
# cleanup and reduce db if any previous data was removed
self.upgrade_log(u'Performing a vacuum on the database.', logger.DEBUG)
self.connection.action('VACUUM')
return self.checkDBVersion()
# 12 -> 13
class AddShowidTvdbidIndex(db.SchemaUpgrade):
# Adding index on tvdb_id (tv_shows) and showid (tv_episodes) to speed up searches/queries
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Checking for duplicate shows before adding unique index.')
MainSanityCheck(self.connection).fix_duplicate_shows('tvdb_id')
self.upgrade_log(u'Adding index on tvdb_id (tv_shows) and showid (tv_episodes) to speed up searches/queries.')
if not self.hasTable('idx_showid'):
self.connection.action('CREATE INDEX idx_showid ON tv_episodes (showid);')
if not self.hasTable('idx_tvdb_id'):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('CREATE UNIQUE INDEX idx_tvdb_id ON tv_shows (tvdb_id);')
self.incDBVersion()
return self.checkDBVersion()
# 13 -> 14
class AddLastUpdateTVDB(db.SchemaUpgrade):
# Adding column last_update_tvdb to tv_shows for controlling nightly updates
def execute(self):
if not self.hasColumn('tv_shows', 'last_update_tvdb'):
self.upgrade_log(u'Adding column last_update_tvdb to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'last_update_tvdb', default=1)
self.incDBVersion()
return self.checkDBVersion()
# 14 -> 15
class AddDBIncreaseTo15(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Bumping database version to v%s' % self.checkDBVersion())
self.incDBVersion()
return self.checkDBVersion()
# 15 -> 16
class AddIMDbInfo(db.SchemaUpgrade):
def execute(self):
db_backed_up = False
if not self.hasTable('imdb_info'):
self.upgrade_log(u'Creating IMDb table imdb_info')
db.backup_database('sickbeard.db', self.checkDBVersion())
db_backed_up = True
self.connection.action(
'CREATE TABLE imdb_info (tvdb_id INTEGER PRIMARY KEY, imdb_id TEXT, title TEXT, year NUMERIC,'
' akas TEXT, runtimes NUMERIC, genres TEXT, countries TEXT, country_codes TEXT, certificates TEXT,'
' rating TEXT, votes INTEGER, last_update NUMERIC)')
if not self.hasColumn('tv_shows', 'imdb_id'):
self.upgrade_log(u'Adding IMDb column imdb_id to tv_shows')
if not db_backed_up:
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'imdb_id')
self.incDBVersion()
return self.checkDBVersion()
# 16 -> 17
class AddProperNamingSupport(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_shows', 'imdb_id')\
and self.hasColumn('tv_shows', 'rls_require_words')\
and self.hasColumn('tv_shows', 'rls_ignore_words'):
return self.setDBVersion(5816)
if not self.hasColumn('tv_episodes', 'is_proper'):
self.upgrade_log(u'Adding column is_proper to tv_episodes')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_episodes', 'is_proper')
self.incDBVersion()
return self.checkDBVersion()
# 17 -> 18
class AddEmailSubscriptionTable(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_episodes', 'is_proper')\
and self.hasColumn('tv_shows', 'rls_require_words')\
and self.hasColumn('tv_shows', 'rls_ignore_words')\
and self.hasColumn('tv_shows', 'skip_notices'):
return self.setDBVersion(5817)
if not self.hasColumn('tv_shows', 'notify_list'):
self.upgrade_log(u'Adding column notify_list to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'notify_list', 'TEXT', None)
self.incDBVersion()
return self.checkDBVersion()
# 18 -> 19
class AddProperSearch(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_episodes', 'is_proper'):
return self.setDBVersion(12)
if not self.hasColumn('tv_shows', 'notify_list')\
and self.hasColumn('tv_shows', 'rls_require_words')\
and self.hasColumn('tv_shows', 'rls_ignore_words')\
and self.hasColumn('tv_shows', 'skip_notices')\
and self.hasColumn('history', 'source'):
return self.setDBVersion(5818)
if not self.hasColumn('info', 'last_proper_search'):
self.upgrade_log(u'Adding column last_proper_search to info')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('info', 'last_proper_search', default=1)
self.incDBVersion()
return self.checkDBVersion()
# 19 -> 20
class AddDvdOrderOption(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_shows', 'dvdorder'):
self.upgrade_log(u'Adding column dvdorder to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'dvdorder', 'NUMERIC', '0')
self.incDBVersion()
return self.checkDBVersion()
11 years ago
# 20 -> 21
class AddSubtitlesSupport(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_shows', 'subtitles'):
self.upgrade_log(u'Adding subtitles to tv_shows and tv_episodes')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'subtitles')
self.addColumn('tv_episodes', 'subtitles', 'TEXT', '')
self.addColumn('tv_episodes', 'subtitles_searchcount')
self.addColumn('tv_episodes', 'subtitles_lastsearch', 'TIMESTAMP', str(datetime.datetime.min))
self.incDBVersion()
return self.checkDBVersion()
# 21 -> 22
class ConvertTVShowsToIndexerScheme(db.SchemaUpgrade):
11 years ago
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Converting TV Shows table to Indexer Scheme...')
if self.hasTable('tmp_tv_shows'):
self.upgrade_log(u'Removing temp tv show tables left behind from previous updates...')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_tv_shows')
self.connection.action('ALTER TABLE tv_shows RENAME TO tmp_tv_shows')
self.connection.action(
'CREATE TABLE tv_shows (show_id INTEGER PRIMARY KEY, indexer_id NUMERIC, indexer NUMERIC, show_name TEXT,'
' location TEXT, network TEXT, genre TEXT, classification TEXT, runtime NUMERIC, quality NUMERIC,'
' airs TEXT, status TEXT, flatten_folders NUMERIC, paused NUMERIC, startyear NUMERIC, air_by_date NUMERIC,'
' lang TEXT, subtitles NUMERIC, notify_list TEXT, imdb_id TEXT,'
' last_update_indexer NUMERIC, dvdorder NUMERIC)')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action(
'INSERT INTO tv_shows(show_id, indexer_id, show_name, location, network, genre, runtime, quality, airs,'
' status, flatten_folders, paused, startyear, air_by_date, lang, subtitles, notify_list, imdb_id,'
' last_update_indexer, dvdorder)'
' SELECT show_id, tvdb_id, show_name, location, network, genre, runtime,'
' quality, airs, status, flatten_folders, paused, startyear, air_by_date, lang, subtitles, notify_list,'
' imdb_id, last_update_tvdb, dvdorder FROM tmp_tv_shows')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_tv_shows')
self.connection.action('CREATE UNIQUE INDEX idx_indexer_id ON tv_shows (indexer_id);')
# noinspection SqlResolve,SqlConstantCondition
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.connection.action('UPDATE tv_shows SET classification = "Scripted" WHERE 1=1')
# noinspection SqlConstantCondition
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.connection.action('UPDATE tv_shows SET indexer = 1 WHERE 1=1')
self.incDBVersion()
return self.checkDBVersion()
# 22 -> 23
class ConvertTVEpisodesToIndexerScheme(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Converting TV Episodes table to Indexer Scheme...')
if self.hasTable('tmp_tv_episodes'):
self.upgrade_log(u'Removing temp tv episode tables left behind from previous updates...')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_tv_episodes')
self.connection.action('ALTER TABLE tv_episodes RENAME TO tmp_tv_episodes')
self.connection.action(
'CREATE TABLE tv_episodes (episode_id INTEGER PRIMARY KEY, showid NUMERIC, indexerid NUMERIC,'
' indexer NUMERIC, name TEXT, season NUMERIC, episode NUMERIC, description TEXT, airdate NUMERIC,'
' hasnfo NUMERIC, hastbn NUMERIC, status NUMERIC, location TEXT, file_size NUMERIC, release_name TEXT,'
' subtitles TEXT, subtitles_searchcount NUMERIC, subtitles_lastsearch TIMESTAMP, is_proper NUMERIC)')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action(
'INSERT INTO tv_episodes(episode_id, showid, indexerid, name, season, episode, description, airdate,'
' hasnfo, hastbn, status, location, file_size, release_name, subtitles, subtitles_searchcount,'
' subtitles_lastsearch, is_proper) SELECT episode_id, showid, tvdbid, name, season, episode, description,'
' airdate, hasnfo, hastbn, status, location, file_size, release_name, subtitles, subtitles_searchcount,'
' subtitles_lastsearch, is_proper FROM tmp_tv_episodes')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_tv_episodes')
self.connection.action('CREATE INDEX idx_tv_episodes_showid_airdate ON tv_episodes(showid,airdate);')
self.connection.action('CREATE INDEX idx_showid ON tv_episodes (showid);')
self.connection.action('CREATE INDEX idx_status ON tv_episodes (status,season,episode,airdate)')
self.connection.action('CREATE INDEX idx_sta_epi_air ON tv_episodes (status,episode, airdate)')
self.connection.action('CREATE INDEX idx_sta_epi_sta_air ON tv_episodes (season,episode, status, airdate)')
# noinspection SqlConstantCondition
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.connection.action('UPDATE tv_episodes SET indexer = 1 WHERE 1=1')
self.incDBVersion()
return self.checkDBVersion()
# 23 -> 24
class ConvertIMDBInfoToIndexerScheme(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.upgrade_log(u'Converting IMDb Info table to Indexer Scheme...')
if self.hasTable('tmp_imdb_info'):
self.upgrade_log(u'Removing temp imdb info tables left behind from previous updates...')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_imdb_info')
self.connection.action('ALTER TABLE imdb_info RENAME TO tmp_imdb_info')
self.connection.action(
'CREATE TABLE imdb_info (indexer_id INTEGER PRIMARY KEY, imdb_id TEXT, title TEXT, year NUMERIC, akas TEXT,'
' runtimes NUMERIC, genres TEXT, countries TEXT, country_codes TEXT, certificates TEXT, rating TEXT,'
' votes INTEGER, last_update NUMERIC)')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action(
'INSERT INTO imdb_info(indexer_id, imdb_id, title, year, akas, runtimes, genres, countries, country_codes,'
' certificates, rating, votes, last_update) SELECT tvdb_id, imdb_id, title, year, akas, runtimes, genres,'
' countries, country_codes, certificates, rating, votes, last_update FROM tmp_imdb_info')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_imdb_info')
self.incDBVersion()
return self.checkDBVersion()
# 24 -> 25
class ConvertInfoToIndexerScheme(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Converting Info table to Indexer Scheme...')
if self.hasTable('tmp_info'):
self.upgrade_log(u'Removing temp info tables left behind from previous updates...')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_info')
self.connection.action('ALTER TABLE info RENAME TO tmp_info')
self.connection.action(
'CREATE TABLE info (last_backlog NUMERIC, last_indexer NUMERIC, last_proper_search NUMERIC)')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action(
'INSERT INTO info(last_backlog, last_indexer, last_proper_search)'
' SELECT last_backlog, last_tvdb, last_proper_search FROM tmp_info')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE tmp_info')
self.incDBVersion()
return self.checkDBVersion()
# 25 -> 26
class AddArchiveFirstMatchOption(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
if not self.hasColumn('tv_shows', 'archive_firstmatch'):
self.upgrade_log(u'Adding column archive_firstmatch to tv_shows')
self.addColumn('tv_shows', 'archive_firstmatch', 'NUMERIC', '0')
self.incDBVersion()
return self.checkDBVersion()
# 26 -> 27
class AddSceneNumbering(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
if self.hasTable('scene_numbering'):
self.connection.action('DROP TABLE scene_numbering')
self.upgrade_log(u'Upgrading table scene_numbering ...')
self.connection.action(
'CREATE TABLE scene_numbering (indexer TEXT, indexer_id INTEGER, season INTEGER, episode INTEGER,'
' scene_season INTEGER, scene_episode INTEGER,'
' PRIMARY KEY (indexer_id,season,episode))')
self.incDBVersion()
return self.checkDBVersion()
# 27 -> 28
class ConvertIndexerToInteger(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
cl = []
self.upgrade_log(u'Converting Indexer to Integer ...')
cl.append(['UPDATE tv_shows SET indexer = ? WHERE LOWER(indexer) = ?', ['1', 'tvdb']])
cl.append(['UPDATE tv_shows SET indexer = ? WHERE LOWER(indexer) = ?', ['2', 'tvrage']])
cl.append(['UPDATE tv_episodes SET indexer = ? WHERE LOWER(indexer) = ?', ['1', 'tvdb']])
cl.append(['UPDATE tv_episodes SET indexer = ? WHERE LOWER(indexer) = ?', ['2', 'tvrage']])
cl.append(['UPDATE scene_numbering SET indexer = ? WHERE LOWER(indexer) = ?', ['1', 'tvdb']])
cl.append(['UPDATE scene_numbering SET indexer = ? WHERE LOWER(indexer) = ?', ['2', 'tvrage']])
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
self.connection.mass_action(cl)
self.incDBVersion()
return self.checkDBVersion()
# 28 -> 29
class AddRequireAndIgnoreWords(db.SchemaUpgrade):
# Adding column rls_require_words and rls_ignore_words to tv_shows
def execute(self):
if self.hasColumn('tv_shows', 'rls_require_words') and self.hasColumn('tv_shows', 'rls_ignore_words'):
self.incDBVersion()
return self.checkDBVersion()
db_backed_up = False
if not self.hasColumn('tv_shows', 'rls_require_words'):
self.upgrade_log(u'Adding column rls_require_words to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
db_backed_up = True
self.addColumn('tv_shows', 'rls_require_words', 'TEXT', '')
if not self.hasColumn('tv_shows', 'rls_ignore_words'):
self.upgrade_log(u'Adding column rls_ignore_words to tv_shows')
if not db_backed_up:
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'rls_ignore_words', 'TEXT', '')
self.incDBVersion()
return self.checkDBVersion()
# 29 -> 30
class AddSportsOption(db.SchemaUpgrade):
def execute(self):
db_backed_up = False
if not self.hasColumn('tv_shows', 'sports'):
self.upgrade_log(u'Adding column sports to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
db_backed_up = True
self.addColumn('tv_shows', 'sports', 'NUMERIC', '0')
if self.hasColumn('tv_shows', 'air_by_date') and self.hasColumn('tv_shows', 'sports'):
# update sports column
self.upgrade_log(u'[4/4] Updating tv_shows to reflect the correct sports value...')
if not db_backed_up:
db.backup_database('sickbeard.db', self.checkDBVersion())
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
cl = []
history_quality = self.connection.select(
'SELECT * FROM tv_shows WHERE LOWER(classification) = "sports" AND air_by_date = 1 AND sports = 0')
for cur_entry in history_quality:
cl.append(['UPDATE tv_shows SET sports = ? WHERE show_id = ?',
[cur_entry['air_by_date'], cur_entry['show_id']]])
cl.append(['UPDATE tv_shows SET air_by_date = 0 WHERE show_id = ?', [cur_entry['show_id']]])
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
self.connection.mass_action(cl)
self.incDBVersion()
return self.checkDBVersion()
# 30 -> 31
class AddSceneNumberingToTvEpisodes(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Adding columns scene_season and scene_episode to tvepisodes')
self.addColumn('tv_episodes', 'scene_season', 'NUMERIC', 'NULL')
self.addColumn('tv_episodes', 'scene_episode', 'NUMERIC', 'NULL')
self.incDBVersion()
return self.checkDBVersion()
# 31 -> 32
class AddAnimeTVShow(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Adding column anime to tv_episodes')
self.addColumn('tv_shows', 'anime', 'NUMERIC', '0')
self.incDBVersion()
return self.checkDBVersion()
# 32 -> 33
class AddAbsoluteNumbering(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Adding column absolute_number to tv_episodes')
self.addColumn('tv_episodes', 'absolute_number', 'NUMERIC', '0')
self.incDBVersion()
return self.checkDBVersion()
# 33 -> 34
class AddSceneAbsoluteNumbering(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Adding columns absolute_number and scene_absolute_number to scene_numbering')
self.addColumn('scene_numbering', 'absolute_number', 'NUMERIC', '0')
self.addColumn('scene_numbering', 'scene_absolute_number', 'NUMERIC', '0')
self.incDBVersion()
return self.checkDBVersion()
# 34 -> 35
class AddAnimeAllowlistBlocklist(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
cl = [['CREATE TABLE allowlist (show_id INTEGER, range TEXT, keyword TEXT, indexer NUMERIC)'],
['CREATE TABLE blocklist (show_id INTEGER, range TEXT, keyword TEXT, indexer NUMERIC)']]
self.upgrade_log(u'Creating tables for anime allow and block lists')
Fixed issues with editing/saving custom scene exceptions. Fixed charmap issues for anime show names. Fixed issues with display show page and epCat key errors. Fixed duplicate log messages for clearing provider caches. Fixed issues with email notifier ep names not properly being encoded to UTF-8. TVDB&lt;-&gt;TVRAGE Indexer ID mapping is now performed on demand to be used when needed such as newznab providers can be searched with tvrage_id&#39;s and some will return tvrage_id&#39;s that later can be used to create show objects from for faster and more accurate name parsing, mapping is done via Trakt API calls. Added stop event signals to schedualed tasks, SR now waits indefinate till task has been fully stopped before completing a restart or shutdown event. NameParserCache is now persistent and stores 200 parsed results at any given time for quicker lookups and better performance, this helps maintain results between updates or shutdown/startup events. Black and White lists for anime now only get used for anime shows as intended, performance gain for non-anime shows that dont need to load these lists. Internal name cache now builds it self on demand when needed per show request plus checks if show is already in cache and if true exits routine to save time. Schedualer and QueueItems classes are now a sub-class of threading.Thread and a stop threading event signal has been added to each. If I forgot to list something it doesn&#39;t mean its not fixed so please test and report back if anything is wrong or has been corrected by this new release.
11 years ago
self.connection.mass_action(cl)
self.incDBVersion()
return self.checkDBVersion()
# 35 -> 36
class AddSceneAbsoluteNumbering2(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Adding column scene_absolute_number to tv_episodes')
self.addColumn('tv_episodes', 'scene_absolute_number', 'NUMERIC', '0')
self.incDBVersion()
return self.checkDBVersion()
# 36 -> 37
class AddXemRefresh(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Creating table xem_refresh')
self.connection.action(
'CREATE TABLE xem_refresh (indexer TEXT, indexer_id INTEGER PRIMARY KEY, last_refreshed INTEGER)')
self.incDBVersion()
return self.checkDBVersion()
# 37 -> 38
class AddSceneToTvShows(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Adding column scene to tv_shows')
self.addColumn('tv_shows', 'scene', 'NUMERIC', '0')
self.incDBVersion()
return self.checkDBVersion()
# 38 -> 39
class AddIndexerMapping(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
if self.hasTable('indexer_mapping'):
self.connection.action('DROP TABLE indexer_mapping')
self.upgrade_log(u'Adding table indexer_mapping')
self.connection.action(
'CREATE TABLE indexer_mapping (indexer_id INTEGER, indexer NUMERIC, mindexer_id INTEGER, mindexer NUMERIC,'
' PRIMARY KEY (indexer_id, indexer))')
self.incDBVersion()
return self.checkDBVersion()
11 years ago
# 39 -> 40
class AddVersionToTvEpisodes(db.SchemaUpgrade):
11 years ago
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
11 years ago
self.upgrade_log(u'Adding columns release_group and version to tv_episodes')
self.addColumn('tv_episodes', 'release_group', 'TEXT', '')
self.addColumn('tv_episodes', 'version', 'NUMERIC', '-1')
self.upgrade_log(u'Adding column version to history')
self.addColumn('history', 'version', 'NUMERIC', '-1')
11 years ago
self.incDBVersion()
return self.checkDBVersion()
# 40 -> 10000
class BumpDatabaseVersion(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Bumping database version')
return self.setDBVersion(10000)
# 41,42 -> 10001
class Migrate41(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Bumping database version')
return self.setDBVersion(10001)
# 43,44 -> 10001
class Migrate43(db.SchemaUpgrade):
def execute(self):
db_backed_up = False
db_chg = None
table = 'tmdb_info'
if self.hasTable(table):
db.backup_database('sickbeard.db', self.checkDBVersion())
db_backed_up = True
self.upgrade_log(u'Dropping redundant table tmdb_info')
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
self.connection.action('DROP TABLE [%s]' % table)
db_chg = True
if self.hasColumn('tv_shows', 'tmdb_id'):
if not db_backed_up:
db.backup_database('sickbeard.db', self.checkDBVersion())
db_backed_up = True
self.upgrade_log(u'Dropping redundant tmdb_info refs')
self.dropColumn('tv_shows', 'tmdb_id')
db_chg = True
if not self.hasTable('db_version'):
if not db_backed_up:
db.backup_database('sickbeard.db', self.checkDBVersion())
self.connection.action('PRAGMA user_version = 0')
self.connection.action('CREATE TABLE db_version (db_version INTEGER);')
self.connection.action('INSERT INTO db_version (db_version) VALUES (0);')
if not db_chg:
self.upgrade_log(u'Bumping database version')
return self.setDBVersion(10001)
# 4301 -> 10002
class Migrate4301(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Bumping database version')
return self.setDBVersion(10002)
# 4302,4400 -> 10003
class Migrate4302(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Bumping database version')
return self.setDBVersion(10003)
# 5816 - 5818 -> 15
class MigrateUpstream(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Migrate SickBeard db v%s into v15' % str(self.checkDBVersion()).replace('58', ''))
return self.setDBVersion(15)
# 10000 -> 20000
class SickGearDatabaseVersion(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Bumping database version to new SickGear standards')
return self.setDBVersion(20000)
# 10001 -> 10000
class RemoveDefaultEpStatusFromTvShows(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Dropping redundant column default_ep_status from tv_shows')
self.dropColumn('tv_shows', 'default_ep_status')
return self.setDBVersion(10000)
# 10002 -> 10001
class RemoveMinorDBVersion(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Dropping redundant column db_minor_version from db_version')
self.dropColumn('db_version', 'db_minor_version')
return self.setDBVersion(10001)
# 10003 -> 10002
class RemoveMetadataSub(db.SchemaUpgrade):
def execute(self):
if self.hasColumn('tv_shows', 'sub_use_sr_metadata'):
self.upgrade_log(u'Dropping redundant column metadata sub')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.dropColumn('tv_shows', 'sub_use_sr_metadata')
return self.setDBVersion(10002)
# 20000 -> 20001
class DBIncreaseTo20001(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
self.upgrade_log(u'Bumping database version to force a backup before new database code')
self.connection.action('VACUUM')
self.upgrade_log(u'Performed a vacuum on the database', logger.DEBUG)
return self.setDBVersion(20001)
# 20001 -> 20002
class AddTvShowOverview(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_shows', 'overview'):
self.upgrade_log(u'Adding column overview to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'overview', 'TEXT', '')
return self.setDBVersion(20002)
# 20002 -> 20003
class AddTvShowTags(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_shows', 'tag'):
self.upgrade_log(u'Adding tag to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'tag', 'TEXT', 'Show List')
return self.setDBVersion(20003)
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
# 20003 -> 20004
class ChangeMapIndexer(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
if self.hasTable('indexer_mapping'):
self.connection.action('DROP TABLE indexer_mapping')
self.upgrade_log(u'Changing table indexer_mapping')
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
self.connection.action(
'CREATE TABLE indexer_mapping (indexer_id INTEGER, indexer NUMERIC, mindexer_id INTEGER NOT NULL,'
' mindexer NUMERIC, date NUMERIC NOT NULL DEFAULT 0, status INTEGER NOT NULL DEFAULT 0,'
' PRIMARY KEY (indexer_id, indexer, mindexer))')
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
self.connection.action('CREATE INDEX IF NOT EXISTS idx_mapping ON indexer_mapping (indexer_id, indexer)')
if not self.hasColumn('info', 'last_run_backlog'):
self.upgrade_log('Adding last_run_backlog to info')
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
self.addColumn('info', 'last_run_backlog', 'NUMERIC', 1)
self.upgrade_log(u'Moving table scene_exceptions from cache.db to sickbeard.db')
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
if self.hasTable('scene_exceptions_refresh'):
self.connection.action('DROP TABLE scene_exceptions_refresh')
self.connection.action('CREATE TABLE scene_exceptions_refresh (list TEXT PRIMARY KEY, last_refreshed INTEGER)')
if self.hasTable('scene_exceptions'):
self.connection.action('DROP TABLE scene_exceptions')
self.connection.action('CREATE TABLE scene_exceptions (exception_id INTEGER PRIMARY KEY,'
' indexer_id INTEGER KEY, show_name TEXT, season NUMERIC, custom NUMERIC)')
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
try:
cachedb = db.DBConnection(filename='cache.db')
if cachedb.hasTable('scene_exceptions'):
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
sql_result = cachedb.action('SELECT * FROM scene_exceptions')
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
cs = []
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
for cur_result in sql_result:
cs.append(
['INSERT OR REPLACE INTO scene_exceptions (exception_id, indexer_id, show_name, season, custom)'
' VALUES (?,?,?,?,?)',
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
[cur_result['exception_id'], cur_result['indexer_id'],
cur_result['show_name'], cur_result['season'], cur_result['custom']]])
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
if 0 < len(cs):
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
self.connection.mass_action(cs)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
except (BaseException, Exception):
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
pass
keep_tables = {'allowlist', 'blocklist', 'whitelist', 'blacklist',
'scene_exceptions', 'scene_exceptions_refresh', 'info', 'indexer_mapping',
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
'db_version', 'history', 'imdb_info', 'lastUpdate', 'scene_numbering', 'tv_episodes', 'tv_shows',
'xem_refresh'}
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
current_tables = set(self.listTables())
remove_tables = list(current_tables - keep_tables)
for table in remove_tables:
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# noinspection SqlResolve
Add smart logic to reduce api hits to newznab server types and improve how nzbs are downloaded. Add newznab smart logic to avoid missing releases when there are a great many recent releases. Change improve performance by using newznab server advertised capabilities. Change config/providers newznab to display only non-default categories. Change use scene season for wanted segment in backlog if show is scene numbering. Change combine Manage Searches / Backlog Search / Limited and Full to Force. Change consolidate limited and full backlog. Change config / Search / Backlog search frequency to instead spread backlog searches over a number of days. Change migrate minimum used value for search frequency into new minimum 7 for search spread. Change restrict nzb providers to 1 backlog batch run per day. Add to Config/Search/Unaired episodes/Allow episodes that are released early. Add to Config/Search/Unaired episodes/Use specific api requests to search for early episode releases. Add use related ids for newznab searches to increase search efficiency. Add periodic update of related show ids. Change terminology Edit Show/&#34;Post processing&#34; tab name to &#34;Other&#34;. Add advanced feature &#34;Related show IDs&#34; to Edit Show/Other used for finding episodes and TV info. Add search info source image links to those that have zero id under Edit Show/Other/&#34;Related show IDs&#34;. Add &#34;set master&#34; button to Edit Show/Other/&#34;Related show IDs&#34; for info source that can be changed. Change terminology displayShow &#34;Indexers&#34; to &#34;Links&#34; to cover internal and web links. Change add related show info sources on displayShow page. Change don&#39;t display &#34;temporarily&#34; defunct TVRage image link on displayShow pages unless it is master info source. Change if a defunct info source is the master of a show then present a link on displayShow to edit related show IDs. Change simplify the next backlog search run time display in the page footer. Change try ssl when fetching data thetvdb, imdb, trakt, scene exception. Change improve reliability to Trakt notifier by using show related id support. Change improve config/providers newznab categories layout. Change show loaded log message at start up and include info source. Change if episode has no airdate then set status to unaired (was skipped). Technical Change move scene_exceptions table from cache.db to sickbeard.db. Add related ids to show obj. Add use of mapped indexer ids for newznab. Add indexer to sql in wanted_eps. Add aired in (scene) season for wanted episodes. Add need_anime, need_sports, need_sd, need_hd, need_uhd to wanted episodes and added as parameter to update_providers. Add fix for lib lockfile/mkdirlockfile. Add set master TV info source logic. Change harden ui input validation. Add per action dialog confirmation. Change to reload page under more events. Change implement &#34;Mark all added episodes Wanted to search for releases&#34; when setting new info source.
9 years ago
self.connection.action('DROP TABLE [%s]' % table)
self.connection.action('VACUUM')
return self.setDBVersion(20004)
# 20004 -> 20005
class AddShowNotFoundCounter(db.SchemaUpgrade):
def execute(self):
if not self.hasTable('tv_shows_not_found'):
self.upgrade_log(u'Adding table tv_shows_not_found')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.connection.action(
'CREATE TABLE tv_shows_not_found (indexer NUMERIC NOT NULL, indexer_id NUMERIC NOT NULL,'
' fail_count NUMERIC NOT NULL DEFAULT 0, last_check NUMERIC NOT NULL, last_success NUMERIC,'
' PRIMARY KEY (indexer_id, indexer))')
return self.setDBVersion(20005)
# 20005 -> 20006
class AddFlagTable(db.SchemaUpgrade):
def execute(self):
if not self.hasTable('flags'):
self.upgrade_log(u'Adding table flags')
db.backup_database('sickbeard.db', self.checkDBVersion())
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.connection.action('CREATE TABLE flags (flag PRIMARY KEY NOT NULL )')
return self.setDBVersion(20006)
# 20006 -> 20007
class DBIncreaseTo20007(db.SchemaUpgrade):
def execute(self):
self.upgrade_log(u'Bumping database version')
return self.setDBVersion(20007)
# 20007 -> 20008
class AddWebdlTypesTable(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
self.connection.action('CREATE TABLE webdl_types (dname TEXT NOT NULL , regex TEXT NOT NULL )')
return self.setDBVersion(20008)
# 20008 -> 20009
class AddWatched(db.SchemaUpgrade):
def execute(self):
# remove old table from version 20007
if self.hasTable('tv_episodes_watched') and not self.hasColumn('tv_episodes_watched', 'clientep_id'):
self.connection.action('DROP TABLE tv_episodes_watched')
self.connection.action('VACUUM')
if not self.hasTable('tv_episodes_watched'):
self.upgrade_log(u'Adding table tv_episodes_watched')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.connection.action(
'CREATE TABLE tv_episodes_watched (tvep_id NUMERIC NOT NULL, clientep_id TEXT, label TEXT,'
' played NUMERIC DEFAULT 0 NOT NULL, date_watched NUMERIC NOT NULL, date_added NUMERIC,'
' status NUMERIC, location TEXT, file_size NUMERIC, hide INT default 0 not null)'
)
return self.setDBVersion(20009)
# 20009 -> 20010
class AddPrune(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_shows', 'prune'):
self.upgrade_log('Adding prune to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'prune', 'INT', 0)
return self.setDBVersion(20010)
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# 20010 -> 20011
class AddIndexerToTables(db.SchemaUpgrade):
def execute(self):
sickbeard.helpers.upgrade_new_naming()
db.backup_database('sickbeard.db', self.checkDBVersion())
show_ids = {s['prod_id']: s['tv_id'] for s in
self.connection.select('SELECT indexer AS tv_id, indexer_id AS prod_id FROM tv_shows')}
allowtbl, blocktbl = (('allow', 'block'), ('white', 'black'))[not self.connection.hasTable('blocklist')]
allowtbl, blocktbl = '%slist' % allowtbl, '%slist' % blocktbl
columns = {allowtbl: 'show_id, range, keyword, indexer',
blocktbl: 'show_id, range, keyword, indexer',
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
'history': 'action, date, showid, season, episode, quality, resource, provider, version, indexer',
'scene_exceptions': 'exception_id , indexer_id, show_name, season, custom, indexer'}
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
# add missing indexer column
for t in [(allowtbl, 'show_id'), (blocktbl, 'show_id'),
('history', 'showid'), ('scene_exceptions', 'indexer_id')]:
Change core system to improve performance and facilitate multi TV info sources. Change migrate core objects TVShow and TVEpisode and everywhere that these objects affect. Add message to logs and disable ui backlog buttons when no media provider has active and/or scheduled searching enabled. Change views for py3 compat. Change set default runtime of 5 mins if none is given for layout Day by Day. Add OpenSubtitles authentication support to config/Subtitles/Subtitles Plugin. Add &#34;Enforce media hash match&#34; to config/Subtitles Plugin/Opensubtitles for accurate subs if enabled, but if disabled, search failures will fallback to use less reliable subtitle results. Add Apprise 0.8.0 (6aa52c3). Add hachoir_py3 3.0a6 (5b9e05a). Add sgmllib3k 1.0.0 Update soupsieve 1.9.1 (24859cc) to soupsieve_py2 1.9.5 (6a38398) Add soupsieve_py3 2.0.0.dev (69194a2). Add Tornado_py3 Web Server 6.0.3 (ff985fe). Add xmlrpclib_to 0.1.1 (c37db9e). Remove ancient Growl lib 0.1 Remove xmltodict library. Change requirements.txt for Cheetah3 to minimum 3.2.4 Change update sabToSickBeard. Change update autoProcessTV. Change remove Twitter notifier. Update NZBGet Process Media extension, SickGear-NG 1.7 → 2.4 Update Kodi addon 1.0.3 → 1.0.4 Update ADBA for py3. Update Beautiful Soup 4.8.0 (r526) to 4.8.1 (r531). Update Send2Trash 1.3.0 (a568370) to 1.5.0 (66afce7). Update soupsieve 1.9.1 (24859cc) to 1.9.5 (6a38398). Change use GNTP (Growl Notification Transport Protocol) from Apprise. Change add multi host support to Growl notifier. Fix Growl notifier when using empty password. Change update links for Growl notifications. Change deprecate confg/Notifications/Growl password field as these are now stored with host setting. Fix prevent infinite memoryError from a particular jpg data structure. Change subliminal for py3. Change enzyme for py3. Change browser_ua for py3. Change feedparser for py3 (sgmlib is no longer available on py3 as standardlib so added ext lib) Fix Guessit. Fix parse_xml for py3. Fix name parser with multi eps for py3. Fix tvdb_api fixes for py3 (search show). Fix config/media process to only display &#34;pattern is invalid&#34; qtip on &#34;Episode naming&#34; tab if the associated field is actually visible. Also, if the field becomes hidden due to a setting change, hide any previously displayed qtip. Note for Javascript::getelementbyid (or $(&#39;tag[id=&#34;&lt;name&gt;&#34;&#39;)) is required when an id is being searched in the dom due to &#34;:&#34; used in a shows id name. Change download anidb xml files to main cache folder and use adba lib folder as a last resort. Change create get anidb show groups as centralised helper func and consolidate dupe code. Change move anidb related functions to newly renamed anime.py (from blacklistandwhitelist.py). Change str encode hex no longer exits in py3, use codecs.encode(...) instead. Change fix b64decode on py3 returns bytestrings. Change use binary read when downloading log file via browser to prevent any encoding issues. Change add case insensitive ordering to anime black/whitelist. Fix anime groups list not excluding whitelisted stuff. Change add Windows utf8 fix ... see: ytdl-org/youtube-dl#820 Change if no qualities are wanted, exit manual search thread. Fix keepalive for py3 process media. Change add a once a month update of tvinfo show mappings to the daily updater. Change autocorrect ids of new shows by updating from -8 to 31 days of the airdate of episode one. Add next run time to Manage/Show Tasks/Daily show update. Change when fetching imdb data, if imdb id is an episode id then try to find and use real show id. Change delete diskcache db in imdbpie when value error (due to change in Python version). Change during startup, cleanup any _cleaner.pyc/o to prevent issues when switching python versions. Add .pyc cleaner if python version is switched. Change replace deprecated gettz_db_metadata() and gettz. Change rebrand &#34;SickGear PostProcessing script&#34; to &#34;SickGear Process Media extension&#34;. Change improve setup guide to use the NZBGet version to minimise displayed text based on version. Change NZBGet versions prior to v17 now told to upgrade as those version are no longer supported - code has actually exit on start up for some time but docs were outdated. Change comment out code and unused option sg_base_path. Change supported Python version 2.7.9-2.7.18 inclusive expanded to 3.7.1-3.8.1 inclusive. Change pidfile creation under Linux 0o644. Make logger accept lists to output continuously using the log_lock instead of split up by other processes. Fix long path issues with Windows process media.
6 years ago
if not self.hasColumn(t[0], 'indexer'):
self.upgrade_log(u'Adding TV info support to %s table' % t[0])
self.addColumn(t[0], 'indexer')
cl = []
for s_id, i in iteritems(show_ids):
# noinspection SqlResolve
cl.append(['UPDATE %s SET indexer = ? WHERE %s = ?' % (t[0], t[1]), [i, s_id]])
self.connection.mass_action(cl)
# noinspection SqlResolve
self.connection.action('CREATE INDEX idx_id_indexer_%s ON %s (indexer, %s)' % (t[0], t[0], t[1]))
if 'history' != t[0]:
# remove any unknown ids (exception history table)
# noinspection SqlResolve
self.connection.action('DELETE FROM %s WHERE indexer = ?' % t[0], [0])
if 0 < self.connection.connection.total_changes:
self.upgrade_log('Removed orphaned data from %s' % t[0])
if self.connection.hasTable('backup_%s' % t[0]):
self.upgrade_log('Adding backup data to %s' % t[0])
self.connection.action('REPLACE INTO %s SELECT %s FROM %s' % ('%s (%s)' % (t[0], columns[t[0]]),
columns[t[0]], 'backup_%s' % t[0]))
self.connection.removeTable('backup_%s' % t[0])
# recreate tables that have wrong primary key = indexer_id without indexer
self.upgrade_log('Adding TV info support to scene_numbering')
# noinspection SqlResolve
self.connection.mass_action([['ALTER TABLE scene_numbering RENAME TO tmp_scene_numbering'],
['CREATE TABLE scene_numbering (indexer TEXT, indexer_id INTEGER, season INTEGER, '
'episode INTEGER, scene_season INTEGER, scene_episode INTEGER, '
'absolute_number NUMERIC, scene_absolute_number NUMERIC, '
'PRIMARY KEY (indexer,indexer_id,season,episode))'],
['REPLACE INTO scene_numbering (indexer, indexer_id, '
'season, episode, scene_season, scene_episode, absolute_number, '
'scene_absolute_number) SELECT "0" AS indexer, indexer_id, '
'season, episode, scene_season, scene_episode, absolute_number, '
'scene_absolute_number FROM tmp_scene_numbering'],
['DROP TABLE tmp_scene_numbering']])
cl = []
for s_id, i in iteritems(show_ids):
cl.append(['UPDATE scene_numbering SET indexer = ? WHERE indexer_id = ?', [i, s_id]])
cl.append(['DELETE FROM scene_numbering WHERE indexer = ?', [0]])
self.connection.mass_action(cl)
self.upgrade_log('Adding TV info support to imdb_info')
# noinspection SqlResolve
self.connection.mass_action([['ALTER TABLE imdb_info RENAME TO tmp_imdb_info'],
['CREATE TABLE imdb_info (indexer NUMERIC, indexer_id NUMERIC, imdb_id TEXT, '
'title TEXT, year NUMERIC, akas TEXT, runtimes NUMERIC, genres TEXT, '
'countries TEXT, country_codes TEXT, certificates TEXT, rating TEXT, '
'votes INTEGER, last_update NUMERIC, PRIMARY KEY (indexer,indexer_id))'],
['REPLACE INTO imdb_info (indexer, indexer_id, imdb_id, '
'title, year, akas, runtimes, genres, countries, country_codes, certificates, '
'rating, votes, last_update) SELECT "0" AS indexer, indexer_id, imdb_id, '
'title, year, akas, runtimes, genres, countries, country_codes, certificates, '
'rating, votes, last_update FROM tmp_imdb_info'],
['DROP TABLE tmp_imdb_info']])
cl = []
for s_id, i in iteritems(show_ids):
cl.append(['UPDATE imdb_info SET indexer = ? WHERE indexer_id = ?', [i, s_id]])
cl.append(['DELETE FROM imdb_info WHERE indexer = ?', [0]])
self.connection.mass_action(cl)
self.connection.action('CREATE INDEX idx_id_indexer_imdb_info ON imdb_info (indexer,indexer_id)')
if self.connection.hasTable('backup_imdb_info'):
self.upgrade_log('Adding backup data to imdb_info')
# noinspection SqlResolve
self.connection.action('REPLACE INTO imdb_info (indexer, indexer_id, imdb_id, title, year, akas, '
'runtimes, genres, countries, country_codes, certificates, rating, votes, '
'last_update) SELECT indexer, indexer_id, imdb_id, title, year, akas, runtimes, '
'genres, countries, country_codes, certificates, rating, votes, last_update '
'FROM backup_imdb_info')
self.connection.removeTable('backup_imdb_info')
# remove an index of an no longer existing column
self.upgrade_log('Changing/Re-Creating Indexes')
if self.connection.hasIndex('tv_shows', 'idx_tvdb_id'):
self.connection.removeIndex('tv_shows', 'idx_tvdb_id')
if self.connection.hasIndex('tv_shows', 'idx_indexer_id'):
self.connection.removeIndex('tv_shows', 'idx_indexer_id')
self.connection.action('CREATE UNIQUE INDEX idx_indexer_id ON tv_shows (indexer,indexer_id)')
if self.connection.hasIndex('tv_episodes', 'idx_showid'):
self.connection.removeIndex('tv_episodes', 'idx_showid')
if self.connection.hasIndex('tv_episodes', 'idx_tv_episodes_showid_airdate'):
self.connection.removeIndex('tv_episodes', 'idx_tv_episodes_showid_airdate')
self.connection.action('CREATE INDEX idx_tv_episodes_showid_airdate ON tv_episodes(indexer,showid,airdate)')
if not self.connection.hasIndex('tv_episodes', 'idx_tv_episodes_unique'):
self.connection.action('CREATE UNIQUE INDEX idx_tv_episodes_unique ON '
'tv_episodes(indexer,showid,season,episode)')
if self.connection.hasTable('backup_tv_episodes'):
self.upgrade_log('Adding backup data to tv_episodes')
# noinspection SqlResolve
self.connection.action('REPLACE INTO tv_episodes (episode_id, showid, indexerid, indexer, name, season, '
'episode, description, airdate, hasnfo, hastbn, status, location, file_size, '
'release_name, subtitles, subtitles_searchcount, subtitles_lastsearch, is_proper, '
'scene_season, scene_episode, absolute_number, scene_absolute_number, '
'release_group, version) SELECT episode_id, showid, indexerid, indexer, name, '
'season, episode, description, airdate, hasnfo, hastbn, status, location, '
'file_size, release_name, subtitles, subtitles_searchcount, subtitles_lastsearch, '
'is_proper, scene_season, scene_episode, absolute_number, scene_absolute_number, '
'release_group, version FROM backup_tv_episodes')
self.connection.removeTable('backup_tv_episodes')
if self.connection.hasTable('backup_tv_shows'):
self.upgrade_log('Adding backup data to tv_shows')
# noinspection SqlResolve
self.connection.action('REPLACE INTO tv_shows (show_id, indexer_id, indexer, show_name, location, '
'network, genre, classification, runtime, quality, airs, status, flatten_folders, '
'paused, startyear, air_by_date, lang, subtitles, notify_list, imdb_id, '
'last_update_indexer, dvdorder, archive_firstmatch, rls_require_words, '
'rls_ignore_words, sports, anime, scene, overview, tag, prune) '
'SELECT show_id, indexer_id, '
'indexer, show_name, location, network, genre, classification, runtime, quality, '
'airs, status, flatten_folders, paused, startyear, air_by_date, lang, subtitles, '
'notify_list, imdb_id, last_update_indexer, dvdorder, archive_firstmatch, '
'rls_require_words, rls_ignore_words, sports, anime, scene, overview, tag, prune '
'FROM backup_tv_shows')
self.connection.removeTable('backup_tv_shows')
self.connection.action('VACUUM')
return self.setDBVersion(20011)
# 20011 -> 20012
class AddShowExludeGlobals(db.SchemaUpgrade):
def execute(self):
if not self.hasColumn('tv_shows', 'rls_global_exclude_ignore'):
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
self.upgrade_log('Adding rls_global_exclude_ignore, rls_global_exclude_require to tv_shows')
db.backup_database('sickbeard.db', self.checkDBVersion())
self.addColumn('tv_shows', 'rls_global_exclude_ignore', data_type='TEXT', default='')
self.addColumn('tv_shows', 'rls_global_exclude_require', data_type='TEXT', default='')
if self.hasTable('tv_shows_exclude_backup'):
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
self.upgrade_log('Adding rls_global_exclude_ignore, rls_global_exclude_require from backup to tv_shows')
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
# noinspection SqlResolve
self.connection.mass_action([['UPDATE tv_shows SET rls_global_exclude_ignore = '
'(SELECT te.rls_global_exclude_ignore FROM tv_shows_exclude_backup te WHERE '
'te.show_id = tv_shows.show_id AND te.indexer = tv_shows.indexer), '
'rls_global_exclude_require = (SELECT te.rls_global_exclude_require FROM '
'tv_shows_exclude_backup te WHERE te.show_id = tv_shows.show_id AND '
'te.indexer = tv_shows.indexer) WHERE EXISTS (SELECT 1 FROM '
'tv_shows_exclude_backup WHERE tv_shows.show_id = '
'tv_shows_exclude_backup.show_id AND '
'tv_shows.indexer = tv_shows_exclude_backup.indexer)'],
['DROP TABLE tv_shows_exclude_backup']
])
return self.setDBVersion(20012)
# 20012 -> 20013
class RenameAllowBlockListTables(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
if not self.connection.hasTable('blocklist'):
self.upgrade_log('Renaming allow/block list tables')
for old, new in (('black', 'block'), ('white', 'allow')):
# noinspection SqlResolve
self.connection.mass_action([
['ALTER TABLE %slist RENAME TO tmp_%slist' % (old, new)],
['CREATE TABLE %slist (show_id INTEGER, range TEXT, keyword TEXT, indexer NUMERIC)' % new],
['INSERT INTO %slist(show_id, range, keyword, indexer)'
' SELECT show_id, range, keyword, indexer FROM tmp_%slist' % (new, new)],
['DROP TABLE tmp_%slist' % new]
])
return self.setDBVersion(20013)
# 20013 -> 20014
class AddHistoryHideColumn(db.SchemaUpgrade):
def execute(self):
db.backup_database('sickbeard.db', self.checkDBVersion())
if not self.hasColumn('history', 'hide'):
self.upgrade_log('Adding hide column to history')
self.addColumn('history', 'hide', default=0, set_default=True)
if self.hasTable('history_hide_backup'):
self.upgrade_log('Restoring hide status in history from backup')
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
# noinspection SqlResolve
self.connection.mass_action([
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
UPDATE history SET hide = (SELECT hide FROM history_hide_backup as hh WHERE
hh.ROWID = history.ROWID AND hh.showid = history.showid AND hh.indexer = history.indexer AND
hh.season = history.season AND hh.episode = history.episode AND hh.action = history.action AND
hh.date = history.date)
"""
],
['DROP TABLE history_hide_backup']
])
return self.setDBVersion(20014)
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
# 20014 -> 100008
class ChangeShowData(db.SchemaUpgrade):
def execute(self):
self.upgrade_log('Adding new data columns to tv_shows')
self.addColumns('tv_shows', [('timezone', 'TEXT', ''), ('airtime', 'NUMERIC'),
('network_country', 'TEXT', ''), ('network_country_code', 'TEXT', ''),
('network_id', 'NUMERIC'), ('network_is_stream', 'INTEGER'),
('src_update_timestamp', 'INTEGER')])
self.upgrade_log('Adding new data columns to tv_episodes')
self.addColumns('tv_episodes', [('timezone', 'TEXT', ''), ('airtime', 'NUMERIC'),
('runtime', 'NUMERIC', 0), ('timestamp', 'NUMERIC'),
('network', 'TEXT', ''), ('network_country', 'TEXT', ''),
('network_country_code', 'TEXT', ''), ('network_id', 'NUMERIC'),
('network_is_stream', 'INTEGER')])
self.upgrade_log('Adding Character and Persons tables')
table_create_sql = {
'castlist': [
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
CREATE TABLE castlist
(
id INTEGER PRIMARY KEY AUTOINCREMENT,
indexer NUMERIC NOT NULL,
indexer_id NUMERIC NOT NULL,
character_id NUMERIC NOT NULL,
sort_order NUMERIC DEFAULT 0 NOT NULL,
updated NUMERIC
);
"""
],
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
'idx_castlist': [
['CREATE INDEX idx_castlist ON castlist (indexer, indexer_Id);'],
['CREATE UNIQUE INDEX idx_unique_castlist ON castlist (indexer, indexer_id, character_id);']
],
'characters': [
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
CREATE TABLE characters
(
id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
name TEXT,
bio TEXT,
thumb_url TEXT,
image_url TEXT,
updated NUMERIC
);
"""
]
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
'character_ids': [
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
CREATE TABLE character_ids
(
id INTEGER PRIMARY KEY AUTOINCREMENT,
src NUMERIC NOT NULL,
src_id NUMERIC NOT NULL,
character_id NUMERIC NOT NULL
);
"""
],
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
'idx_character_ids': [
['CREATE UNIQUE INDEX idx_unique_character_ids ON character_ids (src, character_id);'],
['CREATE INDEX idx_character_ids ON character_ids (character_id);']
],
'character_person_map': [
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
CREATE TABLE character_person_map
(
id INTEGER PRIMARY KEY AUTOINCREMENT,
character_id NUMERIC NOT NULL,
person_id NUMERIC NOT NULL
);
"""
],
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
'idx_character_person_map': [
['CREATE INDEX idx_character_person_map_character ON character_person_map (character_id);'],
['CREATE INDEX idx_character_person_map_person ON character_person_map (person_id);'],
['CREATE UNIQUE INDEX idx_unique_character_person ON character_person_map (character_id, person_id);']
],
'character_person_years': [
[
"""CREATE TABLE character_person_years
(
character_id NUMERIC NOT NULL,
person_id NUMERIC NOT NULL,
start_year NUMERIC,
end_year NUMERIC
);
"""
],
],
'idx_character_person_years': [
['CREATE UNIQUE INDEX idx_unique_character_person_years '
'ON character_person_years (character_id, person_id)'],
['CREATE INDEX idx_character_person_years ON character_person_years (character_id)'],
],
'persons': [
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
CREATE TABLE persons
(
id INTEGER PRIMARY KEY AUTOINCREMENT,
name TEXT,
gender INTEGER,
birthdate NUMERIC,
deathdate NUMERIC,
birthplace TEXT,
deathplace TEXT,
height NUMERIC,
realname TEXT,
nicknames TEXT,
akas TEXT,
homepage TEXT,
bio TEXT,
thumb_url TEXT,
image_url TEXT,
updated NUMERIC
);
"""
]
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
'person_ids': [
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
CREATE TABLE person_ids
(
id INTEGER PRIMARY KEY AUTOINCREMENT,
src INTEGER NOT NULL,
src_id TEXT NOT NULL,
person_id NUMERIC NOT NULL
);
"""
],
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
'idx_person_ids': [
['CREATE UNIQUE INDEX idx_unique_person_ids ON person_ids (src, person_id);'],
['CREATE INDEX idx_person_ids ON person_ids (person_id);']
],
'tv_src_switch': [
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
[
"""
CREATE TABLE tv_src_switch
(
old_indexer NUMERIC NOT NULL,
old_indexer_id NUMERIC NOT NULL,
new_indexer NUMERIC NOT NULL,
new_indexer_id NUMERIC,
force_id NUMERIC DEFAULT 0 NOT NULL,
set_pause INTEGER DEFAULT 0 NOT NULL,
mark_wanted INTEGER DEFAULT 0 NOT NULL,
status NUMERIC DEFAULT 0 NOT NULL,
action_id INTEGER NOT NULL,
uid NUMERIC NOT NULL
);
"""
],
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
'idx_tv_src_switch': [
['CREATE UNIQUE INDEX idx_unique_tv_src_switch ON tv_src_switch (old_indexer, old_indexer_id);']
],
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
'switch_ep_result': [
[
"""
CREATE TABLE switch_ep_result
(
old_indexer NUMERIC NOT NULL,
old_indexer_id NUMERIC NOT NULL,
new_indexer NUMERIC NOT NULL,
new_indexer_id NUMERIC NOT NULL,
season NUMERIC NOT NULL,
episode NUMERIC NOT NULL,
reason NUMERIC DEFAULT 0
);
"""
],
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
'idx_switch_ep_result': [
['CREATE INDEX idx_switch_ep_result ON switch_ep_result (new_indexer, new_indexer_id);'],
["""CREATE INDEX idx_unique_switch_ep_result
ON switch_ep_result (new_indexer, new_indexer_id, season, episode, reason);"""],
['CREATE INDEX idx_switch_ep_result_old ON switch_ep_result (old_indexer, old_indexer_id);'],
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
],
}
cl = []
tables = self.list_tables()
for t in ('castlist', 'characters', 'character_ids', 'persons', 'person_ids', 'character_person_map',
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
'character_person_years', 'tv_src_switch', 'switch_ep_result'):
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
if 'backup_%s' % t in tables:
Add UI changes. Changelog --------- Update fancyBox 2.1.6 to 3.5.7 (c4fd903). Update jQ collapser 2.0 → 3.0.1 (c3f95ba). Add glide.js 3.4.0 (e71f8bf) to view-show https://glidejs.com Add object fit image 3.2.4 (f951d2a). Update fanart icon. Change &#34;Import&#34; title to &#34;Path conflict&#34; for clarity. Add when a path conflict occurs during add show, users may enter a new show folder name. Add parsing Kodi show.nfo so import existing page selects any known info source. Change refactor mass_add_table to improve performance, and code clarity. Change find_show_by_id improve performance by iterating less and not using elif after a return. Add a vertical dotted line indication to the final cast slide on view-show. Add glide arrows to view-show. Change improve ui glide panel generally and also on startup. Add dynamic search examples to add show view. Change interface browse cards to new show search. Add search placeholder syntax hints. Add prevent user error on edit-show where &#34;set master&#34; is pending but Update or Cancel Edit is used instead of &#34;Save Changes&#34;. Add rounded borders to cast on view-show. Add character relationship Presenter to Host. Add third person singular pronoun on view show to a character who is portrayed by themself. Add where a character is in multiple shows to the character page. Change display on ui when update cast is in progress and not just queued. Change replace swipe with move event to act on any input type event (e.g. keyboard) for glide. Add click the glide number on view show to change slide times. Add pause to glide. Add cast displayed on view-show is saved whenever the glide is pause. Add restore view-show glide startAt when in pause mode and an image is selected as first to display. Rename from TVMaze &lt; TVmaze in line with their branding. Remove problematic buffering of 20 items on search results. Add 5 mins to Trakt failure retries times. Add spoken height to person. Change improve speed reading for many processes. Fix layout of multiline genre labels on view-show. Change view-show, during adding of a show, cast links will only become links when data is actually ready to be linked to, otherwise, display as textual info. Add new sort option &#34;Combine source&#34; to search show results. Add source provider images to search result items. Fix search box width now that the other select is reinstated. Change correct log messages grammar. Add visual cue of master tv info source to view show. Add new column on manage/Bulk Change for tv info src so that shows can be sorted to isolate a provider for selection. Add to manage/Bulk Change/Edit/TV info source. Add auto redirect from manage/Bulk Change to manage/show-tasks if a TV info source is tasked to change. Change improve manage/Show Tasks html template. Change replace most of inline styles with CSS classes to improve readability and load perf. Change use proper section dividers on manage/Show Tasks. Fix search TVDb links only to contain lang arg, not all. Technical commit messages (combined commits) -------------------------------------------- Add trigger glide count when view-art is clicked as width can change. Fix to restore show_poster due to change that now returns paths to thumbs that may not exist. Fix search box width on Palemoon. Change set initial cast background to full width. Change prevent the case where a cast list of one person will produce one single fixed width 170px box before the view-show js renders the final box width. Fix quotes in actor names breaking data-caption html markup. Add death data to known api attrs, but still not useful yet because cant do multiple actor searches in one call Change refresh font cache for people icon. Fix initialisation of view-show to display overview text where there is no glide cast list. Change improve image captions with text that cannot be copy/pasted in carousel. Fix hash crash when multiple people play a role. Change DRY and skip write nfo if exception from load_cast_from_tvinfo. Change _get_show_data api4 + fallback html complete. Add if SG_DEV_MODE=1 then logs new api4 data keys that can be added. Fix the return and invalid number of #type declarations for the _get_show_data signature in tvdb_api.py. Change more prep to get the request correct for api vs web requests. Change the goal is to make it so that if apikey = &#39;&#39;, the lib will be html sufficient and not use api. Fix closing fb in cases that have less then display items. Fix preventing glide btn from change after fb was closed in paused mode. Fix the pause called when opening glide fb from destroying saved glide position Change wait for fb to init before displaying images. Fix clicking on cloned glider items. Add pause glide when fb is opened Add caption when fb is open. Fix cursor style over glide btn tweak the exclusion case to focus on role surname as that is the false +ve trigger in this instance Fix use role show_obj in cast_characters. Change rename tmpl file. Change tweak glider ui button positions. Change experiment with Cheetah #attr over, it is too shitty to be useful, so reverted it. Fix cast image full image for characters. Add exclusions to person roles relationship builder, and ensure main character presents first. Add glide pinch zoom on mobile devices.. https://github.com/glidejs/glide/issues/507 Fix select top most item by default in info source search results. Fix issues surrounding process to add show that has an existing folder. Add path conflict rename suggest button when adding a show and the folder exists. Fix correctly send tvid:prodid data between find and existing show page. Fix a nasty c_i index exception created by newly added optimisation code. the exception was raised when an existing folder is found and the add btn pressed so that sg would redirect to the existing show path page. If sg was restarted at this point and the page then refreshed in the browser, then fail. Add send slug:value to find show from existing show folder page. Add use info source passed when redirected from existing show to find show. Change improve ui text. Change simplify and improve clarity of the template variables used. Fix passing hash_dir through to massAddTable tmpl as was consumed in webserve parameter functions instead of being passed in kwargs. Change find_show_by_id to be more pythonic in handling falsy values by not crashing if k/v of a dict is Nonetype. Change use helpers md5_for_text instead of hash() function for existing dir path. Change links got too messy, centralise creation into a function to make link params consistent and remove mistakes, from one use to another. Change wherever ui links/images have a ref_id, if id is not original id then include original id in link Change use reference_id for ui where available Change to less volatile ref_id for saving and restoring glide startAt. Change swap order into slowest to fastest for slide time Change move calcSlideCount function to document scope so it can be called on anytime Change call calcSlideCount when livepanel back-art is clicked Fix minor pyc flagged issues in the sql for tv. Change interface browse cards to new search. Changed use of re_imdb in search to helpers and expanded to 10 digits. Add exceptions to cast. Fix view-show episode date for young and restless (and others) cases. Change more tweaking of that ui text until it feels short and sweet. Change data sent to character page, a person is in a `role` playing a character. Change much simplified character logic due to an issue with Patrick Stewart at AD and ST. Change improved about text on character page and add link to characters in related shows. Change move text list processing from template and into backend. Fix crash on get start end year. Change fix and improve wording of ui switching tv info source. Change make sure there is something to glide before even trying to mount it as there is an acknowledged issue that mounting an empty glide can cause 100% browser usage. Change rescale cast images whose width leak out of container in view-show and move js into cast.js Change move ofi.js to inc_top.tmpl Change neaten the edging of person image. Change contain glide to prevent it from interfering where it should not be. Change setupGlide() is reverted as only one setup is needed, and hasGlideMounted is redundant/removed. Change add qTip. Change view-show sanitise startAt incase a switch makes a smaller cast. Change improve glide pause button with multi-click. Fix multi image alignment also fix round corners for wide images. Fix comparison of width for images on person page. More tweaking of css due to incorrect height on view-show. Tidy up glider CSS files locations and remove unused files from repo. Change move displayshow glide css and js to inc_top. Change improve restarting glide after collapse show and hide events. hide event seems to have better continuous flow, but both do at least restart at the correct index now. Add $.dbg var so the output of index can be seen at console level when an event is fired. Add missing arg to calcSlideCount(). Fix for css .. will-change: transform; Change tidy up collapser button, style its anchor instead of the span workaround. Add resize person and character image container if width is smaller then container on modern browsers Tidy up some ui CSS and minimise show airs text and simplify day ranges. Change collapser to remount glide after show/hide. Change put glide mount in try block to prevent it destroying the collapse when hiding. Change position of cast panel to before the overview. Rename js vars from Python to JS camelcase convention. Fix multiple character images. Fix IE compatibility. Fix prevent crash when switch from tvmaze to tdvb and back again, wierd. Change rename templates. Reformat sql so that the multiline statements can be easily copy pasted into a pyc SQL console window for instant execution. Added missing &#39;;&#39; so they copy/paste execute too. Need to drop existing tbl and copy/paste/execute new sql tbl. Change not everything is an error, but everything is a result, therefore, tbl is renamed. Change pushed rollback of renamed tbl. Fix initial sorting of search results. Change text for people queue actions. Fix max age on appearance. Change correct html layout for view source in web browser. Change title for characters in db, and add tip to make explain that a different image can be correctly shown for a different person e.g. animated or multiple people cast like in The Young and Restless - Sandra Nelson (Phyllis Summers). Fix default tvinfo search source for additional source. Change layout of persons. Change make multiple akas easier to read. Fix saving tvmaze in meta .nfo data. Add .nfo scanned once on startup to ensure tvmaze is set up. Change style for cast carousel on view-show. Change style for Cast update button. Change make topbar-notification unified and use for switcher bar. Change correct the indentation to improve maintainability. Change replace the misuse of br with div tags. Change remove spaces that badly affect layout, and use proper layout spacing. Change add confirm action to clear btn and reinstate all clear buttons. Fix Expand/collapse all + include for people queue. Remove redundant spaces. Change hide clear button until table is expanded. Also, move it to the right or expand/collapse btn. Shuffle the html structure around a little to set btn layout horizontally. Fix &#39;More&#39;/&#39;Less&#39; btn on view-show duplicating summary due to cast-holder div tag conflict. Change view-show cast list to display known names before unknown names. Change view-show add placeholder image for cast with no image. Change view-show under indentation used for html of cast block. Add some icon glyphs. Change vertical alignment of cast to be top down to make cast images level. Change cast update icon. Add akas to person. Change reduce find_show_by_id double call into one. Change tidy up get_url.
4 years ago
# noinspection SqlResolve
Add support for multiple TV info sources. Changelog --------- Change improve loading speed of shows at startup. Change improve main execution loop speed. Add force cast update to view show page. Add person view. Add character view. Add characters, person to clean-up cache (30 days). Add reload person, character images every 7 days. Add suppress UI notification for scheduled people updates during show updates and during switching ids. Add resume support of switched shows after restart that switched id but not finished updating. Add failed TV info switches to show tasks page. Add remove item from queue and clear queue test buttons to mange/show-tasks and manage/search-tasks. Change improve show update logic. Add to view-show page a notification message if a show fails to switch. Add check for existing show with new id pair before switching. Change prioritize first episode start year over the start year set at the tv info source. Change delete non existing episodes when switching indexer. Change &#34;exists in db&#34; link on search results page to support any info source. Add TMDB person pics as fallback. Add use person fallback for character images. Add logic to add start, end year in case of multiple characters per person. Change improve speed getting list in the import view. Add abort people cast update when show is deleted, also remove show from any queued show item or search item Support list of names to search for in show search. Change assist user search terms when the actual title of a show is unknown. Add support URLs in search. Change remove year from search term ... year is still used for relevancy order. Add updating show.nfo when a cast changes. Change use longest biography available for output. Add UI requests of details for feb 28 will also return feb 29 in years without feb 29. Add fetch extra data fallback from TMDB for persons. technical commit messages (combined commits) -------------------------------------------- Add tmdb get_trending, get_popular, get_top_rated, discover to tvinfoapi. Add home/get_persons ajax endpoint, currently supports: birthday, deathday, names. Change daily-schedule to new get_episode_time - More TODO Change view-show to use get_episode_time. Add get show updates list in show updater. Add get_episode_time to network_timezones. Add airtime for episode and show to get_episode_time. Small ep obj load performance improvement. Add handle special episodes and assign numbers based on airdate. Add handle tvmaze specials without airdate. Change during switch tv info source, specials are removed from db because of non-existing generic numbering. Change add first/latest regular episode, use first_aired_regular_episode in all places that have airdate of first episode. Add IMDb to person interface. Add akas to person. Add IMDb bio parser. Add TMDB api for people. Add character role start/end year to IMDb api and tv character. Fix updating characters with multiple persons, by limiting to one. Add cache to imdb_api.py. Add cache to tmdb_api: get_person, _search_person. Add cache to trakt get_person, _search_person cache. Improve main execution loop speed https://stackify.com/20-simple-python-performance-tuning-tips/ point: 12 Add network to episode for tvdb_api (from show data). Add fallback for network/timezone for tv episode to tv show. Add skip retrieve_exceptions for tv info sources that don&#39;t have &#39;scene_url&#39;. Change move network load before show load to make sure the tvshow obj timezone can be set (startup). Add datetime.time to/from integer to sbdatetime (hour, minute only). Add load all indexer mapping at once from db during startup. Add load the failed count during startup. Change move sanitize_filename to sg_helpers. Change move download_file to sg_helpers. Add list_tables, list_indexes to db.py. Add multi db column add function. Restore backup tables during upgrade. Use lib.tvinfo_base import everywhere. Add new properties to tvepisode. Add show_updates to indexer endpoint. Add new db schema. Add Character and Persons tables. Add tvmaze_api lib. Add pytvmaze lib. Add debug __repr__ to people/show queue. Add crew to show tvinfo_base. Drop backup tables for now. Don&#39;t save switch refresh, update show queue items (since they are sub queues of switch). Remove show from switched_shows in case it is in it when deleting the show. Use switch queue for manual switch Load/save updated time for person/Character. Add show_queue table. Add _get_item_sql, _delete_item_from_db_sql to search search_queue. Add people_queue type. Add people scheduler. Add people queue. Add tvinfo source switch queue item. Alternate naming for person/character images. Add load and save image/thumb urls for persons. Add load character pics. Add save images for characters. Add save image urls for characters to db. Change limit for person searches to 100 instead of 10 default. Add person verification. Add people_url and character_url to sources that support them. Add save castlist changes. Add remove old characters from castlist. Change optimize find_show_by_id. Change improve debug info for person, character obj. Add db_support_upsert support flag in db.py. Add cast list objs and load from db. Add parse and add additional images to TVInfo. Add optional loading of images and actors/crew. Fix _make_timestamp in py2. Save and load _src_update_time. Change use update time for show updates. Add _set_network optimization. Add src_update_timestamp to tvshow tbl. Add updated_timestamp to TVInfoShow. Add _indexer_update_time TVShow obj. Add support to search for external ids on TV info sources: [TVINFO_TVDB, TVINFO_IMDb, TVINFO_TMDB, TVINFO_TRAKT]. Change show tasks page, keep remove button for failed switches always visible. Add use get_url for tvmaze_api interface (to support failure handling), without changing original lib. Add missing settings in switch show. Add new switch error: TVSWITCH_ID_CONFLICT: &#39;new id conflicts with existing show&#39;. Add messages for manual switch id. Add connection skip handling. Add get_url failure handling to Trakt lib. Add real search_person to tvinfo interface. Change move TMDB api key to tmdb_api. Add get_url usage via tmdb_api. Change join/split of akas/join and sql group_concat to `;;;` to prevent issues with names that may contain comma (`,`). Add Trakt api specific failure times. Add warning about reassigning MEMCACHE Add calc_age to sg_helpers for person page to remove dupe code. Add return age in ajax for persons. Change format dates on person page to honour config/General. Add convert_to_inch_fraction_html to sg_helpers. Change direct assign method instead of wrapper (faster). Change force disk_pickle_protocol=2 for py2 compatibility in tvinfo cache. Add episode rename info during switch. Add save deleted episodes when switching tvinfo source. Add get_switch_changed page. Add force=True to QueueItemRefresh during switch of tvinfo to force rewriting of metadata. Add filter character dupes in tvdb_api only take images for unique character, role combos on tvdb. Fix humanize lib in py27. Add diskcache to tvinfo_base. Add doc files for diskcache lib. Add clean tvinfo to show_updater. Add switch_ep_errors table to sickbeard.db Add debug log message when extra data is fetched for a person. Change make character loading more efficient. Add placeholder image for characters and persons. Change start, end year moved to new extra table to support multiple person per character. Change replace start_year, end_year with persons_years in Character class. Add new table character_person_years, change table structure characters. Add check if show is found for switch pages. Add missing scheduled to cache.db people queue table. Change trakt show search now will ignore failure handling, to make sure it&#39;s always tried when searching for shows. Change add/improve tvmaze id cross search. Change improve search, if only ids are given, resulting seriesnames on source will be used as text search on following tvinfo sources. Add new parameter: prefer_person to imagecache/character endpoint. Add if prefer_person is set and person_id is set to valid person and the character has more then 1 person assigned the character image will not be returned, instead the actors image or the placeholder. Add only take external ids if character is confirmed in logic. Add match name instead of person id for checking same person in show when adding cast for sources without person id (tvdb) Add cache tmdb genres directly in dict for performance.
4 years ago
cl.append(['ALTER TABLE backup_%s RENAME TO %s' % (t, t)])
elif t not in tables:
cl.extend(table_create_sql[t])
if 'idx_%s' % t in table_create_sql:
cl.extend(table_create_sql['idx_%s' % t])
cl.extend(sickbeard.tv.TVShow.orphaned_cast_sql())
if cl:
self.connection.mass_action(cl)
self.connection.action('VACUUM')
self.setDBVersion(100008)
return self.checkDBVersion()