mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-12 16:22:57 -07:00
Remove unused settings
This commit is contained in:
parent
72764c614e
commit
fd35295093
6 changed files with 14 additions and 120 deletions
|
@ -189,7 +189,6 @@ def main():
|
||||||
plexpy.start()
|
plexpy.start()
|
||||||
|
|
||||||
# Open connection for websocket
|
# Open connection for websocket
|
||||||
if plexpy.CONFIG.MONITORING_USE_WEBSOCKET:
|
|
||||||
try:
|
try:
|
||||||
web_socket.start_thread()
|
web_socket.start_thread()
|
||||||
except:
|
except:
|
||||||
|
|
|
@ -798,13 +798,10 @@
|
||||||
</div>
|
</div>
|
||||||
<div id="monitoring_interval_error" class="alert alert-danger settings-alert" role="alert"></div>
|
<div id="monitoring_interval_error" class="alert alert-danger settings-alert" role="alert"></div>
|
||||||
</div>
|
</div>
|
||||||
<p class="help-block">The interval (in seconds) PlexPy will ping your Plex Server. Minimum 30 seconds, recommended 60 seconds.</p>
|
<p class="help-block">
|
||||||
</div>
|
The interval (in seconds) PlexPy will ping your Plex Server. Minimum 30 seconds, recommended 60 seconds.<br />
|
||||||
<div class="checkbox">
|
Note: Only used for checking Plex remote access.
|
||||||
<label>
|
</p>
|
||||||
<input type="checkbox" class="monitor-settings" id="monitoring_use_websocket" name="monitoring_use_websocket" value="1" ${config['monitoring_use_websocket']}> Use Websocket (requires restart) <span style="color: #eb8600; padding-left: 10px;">[experimental]</span>
|
|
||||||
</label>
|
|
||||||
<p class="help-block">Instead of polling the server at regular intervals let the server tell PlexPy when something happens.</p>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="padded-header">
|
<div class="padded-header">
|
||||||
|
@ -836,15 +833,6 @@
|
||||||
</div>
|
</div>
|
||||||
<p class="help-block">The interval (in seconds) an item must be in a playing state before logging it. 0 to disable.</p>
|
<p class="help-block">The interval (in seconds) an item must be in a playing state before logging it. 0 to disable.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="checkbox">
|
|
||||||
<label>
|
|
||||||
<input type="checkbox" id="ip_logging_enable" name="ip_logging_enable" value="1" ${config['ip_logging_enable']}> Enable IP Logging
|
|
||||||
</label>
|
|
||||||
<span id="debugLogCheck" style="color: #eb8600; padding-left: 10px;"></span>
|
|
||||||
<p class="help-block">
|
|
||||||
Enable this to attempt to log the IP address of the user.
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="padded-header">
|
<div class="padded-header">
|
||||||
<h3>Buffer Warnings</h3>
|
<h3>Buffer Warnings</h3>
|
||||||
|
@ -932,7 +920,7 @@
|
||||||
<label>
|
<label>
|
||||||
<input type="checkbox" name="notify_concurrent_by_ip" id="notify_concurrent_by_ip" value="1" ${config['notify_concurrent_by_ip']}> User Concurrent Streams Notifications by IP Address
|
<input type="checkbox" name="notify_concurrent_by_ip" id="notify_concurrent_by_ip" value="1" ${config['notify_concurrent_by_ip']}> User Concurrent Streams Notifications by IP Address
|
||||||
</label>
|
</label>
|
||||||
<p class="help-block">Enable to only get notified of concurrent streams by a single user from different IP addresses.</p>
|
<p class="help-block">Enable to only send a notification of concurrent streams by a single user from different IP addresses.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="notify_concurrent_threshold">User Concurrent Stream Threshold</label>
|
<label for="notify_concurrent_threshold">User Concurrent Stream Threshold</label>
|
||||||
|
@ -954,19 +942,9 @@
|
||||||
<input type="checkbox" name="notify_group_recently_added" id="notify_group_recently_added" value="1" ${config['notify_group_recently_added']}> Group notifications for recently added TV Shows or Music
|
<input type="checkbox" name="notify_group_recently_added" id="notify_group_recently_added" value="1" ${config['notify_group_recently_added']}> Group notifications for recently added TV Shows or Music
|
||||||
</label>
|
</label>
|
||||||
<p class="help-block">
|
<p class="help-block">
|
||||||
Enable to only get one TV Show/Season or Artist/Album notification for a batch of recently added Episodes or Tracks. Movies are unaffected.<br />
|
Enable to only send one TV Show/Season or Artist/Album notification for a batch of recently added Episodes or Tracks. Movies are unaffected.<br />
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
|
||||||
<label for="notify_recently_added_delay">Notification Delay</label>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-2">
|
|
||||||
<input type="text" class="form-control" data-parsley-type="integer" id="notify_recently_added_delay" name="notify_recently_added_delay" value="${config['notify_recently_added_delay']}" size="5" data-parsley-min="60" data-parsley-trigger="change" data-parsley-errors-container="#notify_recently_added_delay_error" required>
|
|
||||||
</div>
|
|
||||||
<div id="notify_recently_added_delay_error" class="alert alert-danger settings-alert" role="alert"></div>
|
|
||||||
</div>
|
|
||||||
<p class="help-block">Set the delay (in seconds) for recently added notifications to allow metadata to be processed. Minimum 60 seconds.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<p><input type="button" class="btn btn-bright save-button" value="Save" data-success="Changes saved successfully"></p>
|
<p><input type="button" class="btn btn-bright save-button" value="Save" data-success="Changes saved successfully"></p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1938,7 +1916,6 @@ $(document).ready(function() {
|
||||||
serverChanged = false;
|
serverChanged = false;
|
||||||
authChanged = false;
|
authChanged = false;
|
||||||
httpChanged = false;
|
httpChanged = false;
|
||||||
monitorChanged = false;
|
|
||||||
directoryChanged = false;
|
directoryChanged = false;
|
||||||
|
|
||||||
// Alert if leaving the page without saving changes to settings
|
// Alert if leaving the page without saving changes to settings
|
||||||
|
@ -1951,7 +1928,7 @@ $(document).ready(function() {
|
||||||
|
|
||||||
// Alert the user that their changes require a restart.
|
// Alert the user that their changes require a restart.
|
||||||
function postSaveChecks() {
|
function postSaveChecks() {
|
||||||
if ((serverChanged && $('#monitoring_use_websocket').is(":checked")) || authChanged || httpChanged || monitorChanged || directoryChanged) {
|
if (serverChanged || authChanged || httpChanged || directoryChanged) {
|
||||||
$('#restart-modal').modal('show');
|
$('#restart-modal').modal('show');
|
||||||
}
|
}
|
||||||
$("#http_hashed_password").val($("#http_hash_password").is(":checked") ? 1 : 0)
|
$("#http_hashed_password").val($("#http_hash_password").is(":checked") ? 1 : 0)
|
||||||
|
@ -2092,10 +2069,6 @@ $(document).ready(function() {
|
||||||
authChanged = true;
|
authChanged = true;
|
||||||
});
|
});
|
||||||
|
|
||||||
$( ".monitor-settings" ).change(function() {
|
|
||||||
monitorChanged = true;
|
|
||||||
});
|
|
||||||
|
|
||||||
$( ".directory-settings" ).change(function() {
|
$( ".directory-settings" ).change(function() {
|
||||||
directoryChanged = true;
|
directoryChanged = true;
|
||||||
});
|
});
|
||||||
|
@ -2211,51 +2184,6 @@ $(document).ready(function() {
|
||||||
pms_logs_debug = false;
|
pms_logs_debug = false;
|
||||||
pms_logs = false;
|
pms_logs = false;
|
||||||
|
|
||||||
// Checks to see if PMS server version is >= 0.9.14 with automaatically logged IP addresses
|
|
||||||
var version = parseInt($.map("${config['pms_version']}".split('-')[0].split('.').slice(0,4), function(v) { return ('0000'+v).substring(v.length); }).join(""));
|
|
||||||
if (version > 900140000) {
|
|
||||||
$("#debugLogCheck").html("IP address is automatically logged for PMS version 0.9.14 and above.");
|
|
||||||
$("#ip_logging_enable").attr("disabled", true);
|
|
||||||
$("#ip_logging_enable").attr("checked", true);
|
|
||||||
pms_version = true;
|
|
||||||
checkLogsPath();
|
|
||||||
} else {
|
|
||||||
// Check to see if debug logs are enabled on the PMS.
|
|
||||||
$.ajax({
|
|
||||||
url: 'get_server_pref',
|
|
||||||
data: { pref: 'logDebug' },
|
|
||||||
async: true,
|
|
||||||
success: function(data) {
|
|
||||||
pms_logs_debug = (data == 'true' ? true : false);
|
|
||||||
// Check to see if our logs folder is set before allowing IP logging to be enabled.
|
|
||||||
checkLogsPath();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
$("#pms_logs_folder").change(function() {
|
|
||||||
checkLogsPath();
|
|
||||||
});
|
|
||||||
|
|
||||||
function checkLogsPath() {
|
|
||||||
pms_logs = ($("#pms_logs_folder").val() == '' ? false : true);
|
|
||||||
// Toggle IP logging checkbox depending on debug logs, and logs path
|
|
||||||
if (!(pms_version)) {
|
|
||||||
if (pms_logs_debug && pms_logs) {
|
|
||||||
$("#ip_logging_enable").attr("disabled", false);
|
|
||||||
$("#debugLogCheck").html("");
|
|
||||||
} else if (!(pms_logs_debug)) {
|
|
||||||
$("#debugLogCheck").html("Debug logging must be enabled on your Plex Server. <a target='_blank' href='${anon_url('https://support.plex.tv/hc/en-us/articles/201643703-Reporting-issues-with-Plex-Media-Server')}'>Click here</a> for help.");
|
|
||||||
$("#ip_logging_enable").attr("disabled", true);
|
|
||||||
$("#ip_logging_enable").attr("checked", false);
|
|
||||||
} else {
|
|
||||||
$("#debugLogCheck").html("You must first define your Plex Server Logs folder path under the Plex Media Server tab.");
|
|
||||||
$("#ip_logging_enable").attr("disabled", true);
|
|
||||||
$("#ip_logging_enable").attr("checked", false);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: 'get_server_pref',
|
url: 'get_server_pref',
|
||||||
data: { pref: 'PublishServerOnPlexOnlineKey' },
|
data: { pref: 'PublishServerOnPlexOnlineKey' },
|
||||||
|
|
|
@ -106,14 +106,6 @@ class ActivityProcessor(object):
|
||||||
timestamp = {'started': started}
|
timestamp = {'started': started}
|
||||||
self.db.upsert('sessions', timestamp, keys)
|
self.db.upsert('sessions', timestamp, keys)
|
||||||
|
|
||||||
# Try and grab IP address from logs (fallback if not on PMS 0.9.14 and above)
|
|
||||||
if not session['ip_address']:
|
|
||||||
if plexpy.CONFIG.IP_LOGGING_ENABLE and plexpy.CONFIG.PMS_LOGS_FOLDER:
|
|
||||||
ip_address = self.find_session_ip(rating_key=session['rating_key'],
|
|
||||||
machine_id=session['machine_id'])
|
|
||||||
ip_address = {'ip_address': ip_address}
|
|
||||||
self.db.upsert('sessions', ip_address, keys)
|
|
||||||
|
|
||||||
if notify:
|
if notify:
|
||||||
plexpy.NOTIFY_QUEUE.put({'stream_data': values, 'notify_action': 'on_concurrent'})
|
plexpy.NOTIFY_QUEUE.put({'stream_data': values, 'notify_action': 'on_concurrent'})
|
||||||
plexpy.NOTIFY_QUEUE.put({'stream_data': values, 'notify_action': 'on_newdevice'})
|
plexpy.NOTIFY_QUEUE.put({'stream_data': values, 'notify_action': 'on_newdevice'})
|
||||||
|
|
|
@ -279,14 +279,6 @@ def import_from_plexivity(database=None, table_name=None, import_ignore_interval
|
||||||
|
|
||||||
logger.debug(u"PlexPy Importer :: Plexivity data import in progress...")
|
logger.debug(u"PlexPy Importer :: Plexivity data import in progress...")
|
||||||
|
|
||||||
logger.debug(u"PlexPy Importer :: Disabling monitoring while import in progress.")
|
|
||||||
plexpy.schedule_job(activity_pinger.check_active_sessions, 'Check for active sessions',
|
|
||||||
hours=0, minutes=0, seconds=0)
|
|
||||||
plexpy.schedule_job(activity_pinger.check_recently_added, 'Check for recently added items',
|
|
||||||
hours=0, minutes=0, seconds=0)
|
|
||||||
plexpy.schedule_job(activity_pinger.check_server_access, 'Check for Plex remote access',
|
|
||||||
hours=0, minutes=0, seconds=0)
|
|
||||||
|
|
||||||
ap = activity_processor.ActivityProcessor()
|
ap = activity_processor.ActivityProcessor()
|
||||||
user_data = users.Users()
|
user_data = users.Users()
|
||||||
|
|
||||||
|
@ -430,9 +422,6 @@ def import_from_plexivity(database=None, table_name=None, import_ignore_interval
|
||||||
logger.debug(u"PlexPy Importer :: Plexivity data import complete.")
|
logger.debug(u"PlexPy Importer :: Plexivity data import complete.")
|
||||||
import_users()
|
import_users()
|
||||||
|
|
||||||
logger.debug(u"PlexPy Importer :: Re-enabling monitoring.")
|
|
||||||
plexpy.initialize_scheduler()
|
|
||||||
|
|
||||||
def import_users():
|
def import_users():
|
||||||
logger.debug(u"PlexPy Importer :: Importing Plexivity Users...")
|
logger.debug(u"PlexPy Importer :: Importing Plexivity Users...")
|
||||||
monitor_db = database.MonitorDatabase()
|
monitor_db = database.MonitorDatabase()
|
||||||
|
|
|
@ -270,14 +270,6 @@ def import_from_plexwatch(database=None, table_name=None, import_ignore_interval
|
||||||
|
|
||||||
logger.debug(u"PlexPy Importer :: PlexWatch data import in progress...")
|
logger.debug(u"PlexPy Importer :: PlexWatch data import in progress...")
|
||||||
|
|
||||||
logger.debug(u"PlexPy Importer :: Disabling monitoring while import in progress.")
|
|
||||||
plexpy.schedule_job(activity_pinger.check_active_sessions, 'Check for active sessions',
|
|
||||||
hours=0, minutes=0, seconds=0)
|
|
||||||
plexpy.schedule_job(activity_pinger.check_recently_added, 'Check for recently added items',
|
|
||||||
hours=0, minutes=0, seconds=0)
|
|
||||||
plexpy.schedule_job(activity_pinger.check_server_access, 'Check for Plex remote access',
|
|
||||||
hours=0, minutes=0, seconds=0)
|
|
||||||
|
|
||||||
ap = activity_processor.ActivityProcessor()
|
ap = activity_processor.ActivityProcessor()
|
||||||
user_data = users.Users()
|
user_data = users.Users()
|
||||||
|
|
||||||
|
@ -423,9 +415,6 @@ def import_from_plexwatch(database=None, table_name=None, import_ignore_interval
|
||||||
logger.debug(u"PlexPy Importer :: PlexWatch data import complete.")
|
logger.debug(u"PlexPy Importer :: PlexWatch data import complete.")
|
||||||
import_users()
|
import_users()
|
||||||
|
|
||||||
logger.debug(u"PlexPy Importer :: Re-enabling monitoring.")
|
|
||||||
plexpy.initialize_scheduler()
|
|
||||||
|
|
||||||
def import_users():
|
def import_users():
|
||||||
logger.debug(u"PlexPy Importer :: Importing PlexWatch Users...")
|
logger.debug(u"PlexPy Importer :: Importing PlexWatch Users...")
|
||||||
monitor_db = database.MonitorDatabase()
|
monitor_db = database.MonitorDatabase()
|
||||||
|
|
|
@ -2559,12 +2559,10 @@ class WebInterface(object):
|
||||||
"monitor_pms_updates": checked(plexpy.CONFIG.MONITOR_PMS_UPDATES),
|
"monitor_pms_updates": checked(plexpy.CONFIG.MONITOR_PMS_UPDATES),
|
||||||
"monitor_remote_access": checked(plexpy.CONFIG.MONITOR_REMOTE_ACCESS),
|
"monitor_remote_access": checked(plexpy.CONFIG.MONITOR_REMOTE_ACCESS),
|
||||||
"monitoring_interval": plexpy.CONFIG.MONITORING_INTERVAL,
|
"monitoring_interval": plexpy.CONFIG.MONITORING_INTERVAL,
|
||||||
"monitoring_use_websocket": checked(plexpy.CONFIG.MONITORING_USE_WEBSOCKET),
|
|
||||||
"refresh_libraries_interval": plexpy.CONFIG.REFRESH_LIBRARIES_INTERVAL,
|
"refresh_libraries_interval": plexpy.CONFIG.REFRESH_LIBRARIES_INTERVAL,
|
||||||
"refresh_libraries_on_startup": checked(plexpy.CONFIG.REFRESH_LIBRARIES_ON_STARTUP),
|
"refresh_libraries_on_startup": checked(plexpy.CONFIG.REFRESH_LIBRARIES_ON_STARTUP),
|
||||||
"refresh_users_interval": plexpy.CONFIG.REFRESH_USERS_INTERVAL,
|
"refresh_users_interval": plexpy.CONFIG.REFRESH_USERS_INTERVAL,
|
||||||
"refresh_users_on_startup": checked(plexpy.CONFIG.REFRESH_USERS_ON_STARTUP),
|
"refresh_users_on_startup": checked(plexpy.CONFIG.REFRESH_USERS_ON_STARTUP),
|
||||||
"ip_logging_enable": checked(plexpy.CONFIG.IP_LOGGING_ENABLE),
|
|
||||||
"movie_logging_enable": checked(plexpy.CONFIG.MOVIE_LOGGING_ENABLE),
|
"movie_logging_enable": checked(plexpy.CONFIG.MOVIE_LOGGING_ENABLE),
|
||||||
"tv_logging_enable": checked(plexpy.CONFIG.TV_LOGGING_ENABLE),
|
"tv_logging_enable": checked(plexpy.CONFIG.TV_LOGGING_ENABLE),
|
||||||
"music_logging_enable": checked(plexpy.CONFIG.MUSIC_LOGGING_ENABLE),
|
"music_logging_enable": checked(plexpy.CONFIG.MUSIC_LOGGING_ENABLE),
|
||||||
|
@ -2574,7 +2572,6 @@ class WebInterface(object):
|
||||||
"notify_upload_posters": checked(plexpy.CONFIG.NOTIFY_UPLOAD_POSTERS),
|
"notify_upload_posters": checked(plexpy.CONFIG.NOTIFY_UPLOAD_POSTERS),
|
||||||
"notify_recently_added": checked(plexpy.CONFIG.NOTIFY_RECENTLY_ADDED),
|
"notify_recently_added": checked(plexpy.CONFIG.NOTIFY_RECENTLY_ADDED),
|
||||||
"notify_group_recently_added": checked(plexpy.CONFIG.NOTIFY_GROUP_RECENTLY_ADDED),
|
"notify_group_recently_added": checked(plexpy.CONFIG.NOTIFY_GROUP_RECENTLY_ADDED),
|
||||||
"notify_recently_added_delay": plexpy.CONFIG.NOTIFY_RECENTLY_ADDED_DELAY,
|
|
||||||
"notify_concurrent_by_ip": checked(plexpy.CONFIG.NOTIFY_CONCURRENT_BY_IP),
|
"notify_concurrent_by_ip": checked(plexpy.CONFIG.NOTIFY_CONCURRENT_BY_IP),
|
||||||
"notify_concurrent_threshold": plexpy.CONFIG.NOTIFY_CONCURRENT_THRESHOLD,
|
"notify_concurrent_threshold": plexpy.CONFIG.NOTIFY_CONCURRENT_THRESHOLD,
|
||||||
"notify_watched_percent": plexpy.CONFIG.NOTIFY_WATCHED_PERCENT,
|
"notify_watched_percent": plexpy.CONFIG.NOTIFY_WATCHED_PERCENT,
|
||||||
|
@ -2634,9 +2631,9 @@ class WebInterface(object):
|
||||||
"launch_browser", "enable_https", "https_create_cert", "api_enabled", "freeze_db", "check_github",
|
"launch_browser", "enable_https", "https_create_cert", "api_enabled", "freeze_db", "check_github",
|
||||||
"grouping_global_history", "grouping_user_history", "grouping_charts", "group_history_tables",
|
"grouping_global_history", "grouping_user_history", "grouping_charts", "group_history_tables",
|
||||||
"pms_use_bif", "pms_ssl", "pms_is_remote", "home_stats_type",
|
"pms_use_bif", "pms_ssl", "pms_is_remote", "home_stats_type",
|
||||||
"movie_notify_enable", "tv_notify_enable", "music_notify_enable", "monitoring_use_websocket",
|
"movie_notify_enable", "tv_notify_enable", "music_notify_enable",
|
||||||
"refresh_libraries_on_startup", "refresh_users_on_startup",
|
"refresh_libraries_on_startup", "refresh_users_on_startup",
|
||||||
"ip_logging_enable", "movie_logging_enable", "tv_logging_enable", "music_logging_enable",
|
"movie_logging_enable", "tv_logging_enable", "music_logging_enable",
|
||||||
"notify_consecutive", "notify_upload_posters", "notify_recently_added", "notify_group_recently_added",
|
"notify_consecutive", "notify_upload_posters", "notify_recently_added", "notify_group_recently_added",
|
||||||
"monitor_pms_updates", "monitor_remote_access", "get_file_sizes", "log_blacklist", "http_hash_password",
|
"monitor_pms_updates", "monitor_remote_access", "get_file_sizes", "log_blacklist", "http_hash_password",
|
||||||
"allow_guest_access", "cache_images", "http_proxy", "http_basic_auth", "notify_concurrent_by_ip",
|
"allow_guest_access", "cache_images", "http_proxy", "http_basic_auth", "notify_concurrent_by_ip",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue