diff --git a/CHANGES.md b/CHANGES.md
index a1c15055..9fbc8cc8 100644
--- a/CHANGES.md
+++ b/CHANGES.md
@@ -12,6 +12,7 @@
* Update urllib3 1.26.14 (a06c05c) to 1.26.15 (25cca389)
* Change add jobs to centralise scheduler activities
* Change refactor scene_exceptions
+* Add config to change media process log message if there is no media to process
### 3.28.0 (2023-04-12 13:05:00 UTC)
diff --git a/gui/slick/interfaces/default/config_postProcessing.tmpl b/gui/slick/interfaces/default/config_postProcessing.tmpl
index b6e52c34..a3a4a191 100644
--- a/gui/slick/interfaces/default/config_postProcessing.tmpl
+++ b/gui/slick/interfaces/default/config_postProcessing.tmpl
@@ -85,7 +85,7 @@
files in the completed TV downloads folder
- note: do not enable with external post processing scripts like sabTosickgear for SABnzbd, or NZBMedia for NZBGET
+ note: do not enable with external post processing scripts like sabTosickgear for SABnzbd, or NZBMedia for NZBGET unless you're an expert
@@ -109,6 +109,17 @@
+
+
+
+ If no media to process
+
+
+ use positive log message "Success, no media to process. "
+ some setups require the old warning "Failed! Did not process any files. "
+
+
+
#if False:
"""
diff --git a/sickgear/__init__.py b/sickgear/__init__.py
index 1accc16d..94102c50 100644
--- a/sickgear/__init__.py
+++ b/sickgear/__init__.py
@@ -295,6 +295,7 @@ PROCESS_LAST_CLEANUP = False
PROCESS_METHOD = None
MOVE_ASSOCIATED_FILES = False
POSTPONE_IF_SYNC_FILES = True
+PROCESS_POSITIVE_LOG = True
NFO_RENAME = True
TV_DOWNLOAD_DIR = None
UNPACK = False
@@ -716,7 +717,7 @@ def init_stage_1(console_logging):
SUBTITLES_HISTORY, SUBTITLES_SERVICES_LIST, SUBTITLES_SERVICES_ENABLED, SUBTITLES_SERVICES_AUTH
# Media Process/Post-Processing
global TV_DOWNLOAD_DIR, PROCESS_METHOD, PROCESS_AUTOMATICALLY, MEDIAPROCESS_INTERVAL, \
- POSTPONE_IF_SYNC_FILES, EXTRA_SCRIPTS, SG_EXTRA_SCRIPTS, \
+ POSTPONE_IF_SYNC_FILES, PROCESS_POSITIVE_LOG, EXTRA_SCRIPTS, SG_EXTRA_SCRIPTS, \
DEFAULT_MEDIAPROCESS_INTERVAL, MIN_MEDIAPROCESS_INTERVAL, \
UNPACK, SKIP_REMOVED_FILES, MOVE_ASSOCIATED_FILES, NFO_RENAME, RENAME_EPISODES, AIRDATE_EPISODES, \
USE_FAILED_DOWNLOADS, DELETE_FAILED
@@ -1022,6 +1023,7 @@ def init_stage_1(console_logging):
PROCESS_LAST_CLEANUP = bool(check_setting_int(CFG, 'General', 'process_last_cleanup', 0))
MOVE_ASSOCIATED_FILES = bool(check_setting_int(CFG, 'General', 'move_associated_files', 0))
POSTPONE_IF_SYNC_FILES = bool(check_setting_int(CFG, 'General', 'postpone_if_sync_files', 1))
+ PROCESS_POSITIVE_LOG = bool(check_setting_int(CFG, 'General', 'process_positive_log', 0))
NFO_RENAME = bool(check_setting_int(CFG, 'General', 'nfo_rename', 1))
CREATE_MISSING_SHOW_DIRS = bool(check_setting_int(CFG, 'General', 'create_missing_show_dirs', 0))
SHOW_DIRS_WITH_DOTS = bool(check_setting_int(CFG, 'General', 'show_dirs_with_dots', 0))
@@ -1989,6 +1991,7 @@ def save_config():
new_config['General']['process_last_cleanup'] = int(PROCESS_LAST_CLEANUP)
new_config['General']['move_associated_files'] = int(MOVE_ASSOCIATED_FILES)
new_config['General']['postpone_if_sync_files'] = int(POSTPONE_IF_SYNC_FILES)
+ new_config['General']['process_positive_log'] = int(PROCESS_POSITIVE_LOG)
new_config['General']['nfo_rename'] = int(NFO_RENAME)
new_config['General']['process_automatically'] = int(PROCESS_AUTOMATICALLY)
new_config['General']['unpack'] = int(UNPACK)
diff --git a/sickgear/processTV.py b/sickgear/processTV.py
index 08c53072..c3fafbae 100644
--- a/sickgear/processTV.py
+++ b/sickgear/processTV.py
@@ -514,7 +514,7 @@ class ProcessTVShow(object):
for f in sorted(list(set([os.path.dirname(item) for item in work_files]) - {path}), key=len, reverse=True):
self._delete_folder(f)
- def _bottom_line(text, log_level=logger.DEBUG):
+ def _bottom_line(text, log_level=logger.MESSAGE):
self._buffer('-' * len(text))
self._log_helper(text, log_level)
@@ -524,11 +524,12 @@ class ProcessTVShow(object):
if self.any_vid_processed:
if not self.files_failed:
- _bottom_line('Successfully processed.', logger.MESSAGE)
+ _bottom_line('Successfully processed.')
else:
_bottom_line(f'Successfully processed at least one video file'
- f'{(", others were skipped", " and skipped another")[1 == self.files_failed]}.',
- logger.MESSAGE)
+ f'{(", others were skipped", " and skipped another")[1 == self.files_failed]}.')
+ elif sickgear.PROCESS_POSITIVE_LOG:
+ _bottom_line('Success, no media to process.')
else:
_bottom_line('Failed! Did not process any files.', logger.WARNING)
diff --git a/sickgear/webserve.py b/sickgear/webserve.py
index 409870fb..4cdeb8f8 100644
--- a/sickgear/webserve.py
+++ b/sickgear/webserve.py
@@ -8504,7 +8504,7 @@ class ConfigMediaProcess(Config):
unpack=None, keep_processed_dir=None, process_method=None,
extra_scripts='', sg_extra_scripts='',
rename_episodes=None, airdate_episodes=None,
- move_associated_files=None, postpone_if_sync_files=None,
+ move_associated_files=None, postpone_if_sync_files=None, process_positive_log=None,
naming_custom_abd=None, naming_custom_sports=None, naming_custom_anime=None,
naming_strip_year=None, use_failed_downloads=None, delete_failed=None,
skip_removed_files=None, nfo_rename=None,
@@ -8541,6 +8541,7 @@ class ConfigMediaProcess(Config):
sickgear.AIRDATE_EPISODES = config.checkbox_to_value(airdate_episodes)
sickgear.MOVE_ASSOCIATED_FILES = config.checkbox_to_value(move_associated_files)
sickgear.POSTPONE_IF_SYNC_FILES = config.checkbox_to_value(postpone_if_sync_files)
+ sickgear.PROCESS_POSITIVE_LOG = config.checkbox_to_value(process_positive_log)
sickgear.NAMING_CUSTOM_ABD = config.checkbox_to_value(naming_custom_abd)
sickgear.NAMING_CUSTOM_SPORTS = config.checkbox_to_value(naming_custom_sports)
sickgear.NAMING_CUSTOM_ANIME = config.checkbox_to_value(naming_custom_anime)