From 1a5cc0209732f6121ff27f3a02c46c6c2ae69a83 Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Fri, 2 Sep 2016 13:01:12 -0700 Subject: [PATCH 01/13] Update with support links --- data/interfaces/default/base.html | 2 + .../default/configuration_table.html | 83 ++++++++++++++----- data/interfaces/default/settings.html | 25 ++---- 3 files changed, 70 insertions(+), 40 deletions(-) diff --git a/data/interfaces/default/base.html b/data/interfaces/default/base.html index a0b0001f..b0722434 100644 --- a/data/interfaces/default/base.html +++ b/data/interfaces/default/base.html @@ -221,6 +221,8 @@
  • View Logs
  • +
  • PlexPy Support
  • +
  • Paypal
  • Bitcoin
  • diff --git a/data/interfaces/default/configuration_table.html b/data/interfaces/default/configuration_table.html index 4dd14b6e..7a1cde15 100644 --- a/data/interfaces/default/configuration_table.html +++ b/data/interfaces/default/configuration_table.html @@ -72,32 +72,67 @@ DOCUMENTATION :: END ${sys.version} - Plex Forums: - https://forums.plex.tv/discussion/169591/plexpy-another-plex-monitoring-program + Resources: + + GitHub Source | + GitHub Issues | + FeatHub Feature Requests | + PlexPy Wiki | + PlexPy FAQ + - Source: - https://github.com/drzoidberg33/plexpy - - - Wiki: - https://github.com/drzoidberg33/plexpy/wiki - - - Issues: - https://github.com/drzoidberg33/plexpy/issues - - - Feature Requests: - http://feathub.com/drzoidberg33/plexpy - - - Gitter Chat: - https://gitter.im/drzoidberg33/plexpy + Support: + + Plex Forums | + PlexPy Gitter Chat | + /r/Plex Discord Server | + PlexPy Discord Server + + + + + \ No newline at end of file diff --git a/data/interfaces/default/settings.html b/data/interfaces/default/settings.html index 6630ff9d..6ca55409 100644 --- a/data/interfaces/default/settings.html +++ b/data/interfaces/default/settings.html @@ -2101,26 +2101,6 @@ - @@ -2141,6 +2121,11 @@ } else if ("${kwargs.get('reinstall_geoip')}" == 'true') { $('#reinstall_geoip_db').removeClass('no-highlight').css('color','#e9a049'); } + if ("${kwargs.get('support')}" == 'true') { + $('.support-modal-link').removeClass('no-highlight').css('color','#e9a049'); + $('#best-support-link').prepend(' ') + $('#best-support-link span').tooltip({ container: 'body' }); + } } }); } From fa51df192d98439376e4cc748b14b1473f9afef8 Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Fri, 2 Sep 2016 13:18:06 -0700 Subject: [PATCH 02/13] Cleanup settings modal text --- data/interfaces/default/settings.html | 58 +++++++++++++-------------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/data/interfaces/default/settings.html b/data/interfaces/default/settings.html index 6ca55409..e4524af3 100644 --- a/data/interfaces/default/settings.html +++ b/data/interfaces/default/settings.html @@ -1264,7 +1264,7 @@ - @@ -1285,7 +1285,7 @@
    + Year
    - @@ -1316,7 +1316,7 @@
    + Month
    - @@ -1337,7 +1337,7 @@
    + Day of the Year
    - @@ -1363,7 +1363,7 @@
    + Day of the Month
    - @@ -1389,7 +1389,7 @@
    + Day of the Week
    - @@ -1420,7 +1420,7 @@
    + Hour
    - @@ -1441,7 +1441,7 @@
    + Minute
    - @@ -1462,7 +1462,7 @@
    + Second
    - @@ -1483,7 +1483,7 @@
    + AM / PM
    - @@ -1504,7 +1504,7 @@
    + Timezone
    - @@ -1574,7 +1574,7 @@
    + Timestamp
    - @@ -1619,7 +1619,7 @@
    + Global
    - @@ -1778,7 +1778,7 @@
    + Stream Details
    - @@ -1915,12 +1915,12 @@ +

    (PMS agent must be Plex Movie)

    +

    (PMS agent must be Plex Movie)

    @@ -1972,7 +1972,7 @@
    + Metadata Details
    {imdb_id} The IMDB ID for the movie. (e.g. tt2488496) -

    (PMS agent must be Freebase)

    {imdb_url} The IMDB URL for the movie. -

    (PMS agent must be Freebase)

    {thetvdb_id}
    - @@ -2039,27 +2039,27 @@ - + - + % endif @@ -74,18 +74,18 @@ DOCUMENTATION :: END diff --git a/plexpy/config.py b/plexpy/config.py index f228056c..4e5f57bb 100644 --- a/plexpy/config.py +++ b/plexpy/config.py @@ -170,7 +170,7 @@ _CONFIG_DEFINITIONS = { 'GIT_BRANCH': (str, 'General', 'master'), 'GIT_PATH': (str, 'General', ''), 'GIT_TOKEN': (str, 'General', ''), - 'GIT_USER': (str, 'General', 'drzoidberg33'), + 'GIT_USER': (str, 'General', 'JonnyWong16'), 'GRAPH_TYPE': (str, 'General', 'plays'), 'GRAPH_DAYS': (int, 'General', 30), 'GRAPH_TAB': (str, 'General', 'tabs-1'), @@ -801,4 +801,9 @@ class Config(object): if self.CONFIG_VERSION == '5': self.MONITOR_PMS_UPDATES = 0 - self.CONFIG_VERSION = '6' \ No newline at end of file + self.CONFIG_VERSION = '6' + + if self.CONFIG_VERSION == '6': + if self.GIT_USER.lower() == 'drzoidberg33': + self.GIT_USER = 'JonnyWong16' + self.CONFIG_VERSION = '7' \ No newline at end of file diff --git a/plexpy/notifiers.py b/plexpy/notifiers.py index 0bff8a62..e1e6944c 100644 --- a/plexpy/notifiers.py +++ b/plexpy/notifiers.py @@ -626,9 +626,9 @@ class PrettyMetadata(object): self.poster_url = self.metadata.get('poster_url','') if not self.poster_url: if self.metadata['media_type'] in ['artist', 'track']: - self.poster_url = 'https://raw.githubusercontent.com/drzoidberg33/plexpy/master/data/interfaces/default/images/cover.png' + self.poster_url = 'https://raw.githubusercontent.com/%s/plexpy/master/data/interfaces/default/images/cover.png' % plexpy.CONFIG.GIT_USER else: - self.poster_url = 'https://raw.githubusercontent.com/drzoidberg33/plexpy/master/data/interfaces/default/images/poster.png' + self.poster_url = 'https://raw.githubusercontent.com/%s/plexpy/master/data/interfaces/default/images/poster.png' % plexpy.CONFIG.GIT_USER return self.poster_url def get_poster_link(self): From 5d604c2cadb9f5af38b2f8c9c5274d904a7b80ee Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Sat, 17 Sep 2016 14:45:58 -0700 Subject: [PATCH 07/13] Make sure all endpoints have kwargs --- plexpy/webserve.py | 76 +++++++++++++++++++++++----------------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/plexpy/webserve.py b/plexpy/webserve.py index 4514c27d..31fc35f5 100644 --- a/plexpy/webserve.py +++ b/plexpy/webserve.py @@ -81,7 +81,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def index(self): + def index(self, **kwargs): if plexpy.CONFIG.FIRST_RUN_COMPLETE: raise cherrypy.HTTPRedirect(plexpy.HTTP_ROOT + "home") else: @@ -168,7 +168,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def home(self): + def home(self, **kwargs): config = { "home_sections": plexpy.CONFIG.HOME_SECTIONS, "home_stats_length": plexpy.CONFIG.HOME_STATS_LENGTH, @@ -329,7 +329,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def delete_temp_sessions(self): + def delete_temp_sessions(self, **kwargs): result = database.delete_sessions() @@ -343,7 +343,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def libraries(self): + def libraries(self, **kwargs): config = { "update_section_ids": plexpy.CONFIG.UPDATE_SECTION_IDS } @@ -469,7 +469,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def library(self, section_id=None): + def library(self, section_id=None, **kwargs): if not allow_session_library(section_id): raise cherrypy.HTTPRedirect(plexpy.HTTP_ROOT) @@ -708,7 +708,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def get_media_info_file_sizes(self, section_id=None, rating_key=None): + def get_media_info_file_sizes(self, section_id=None, rating_key=None, **kwargs): get_file_sizes_hold = plexpy.CONFIG.GET_FILE_SIZES_HOLD section_ids = set(get_file_sizes_hold['section_ids']) rating_keys = set(get_file_sizes_hold['rating_keys']) @@ -999,7 +999,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def delete_duplicate_libraries(self): + def delete_duplicate_libraries(self, **kwargs): library_data = libraries.Libraries() result = library_data.delete_duplicate_libraries() @@ -1013,7 +1013,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def users(self): + def users(self, **kwargs): return serve_template(templatename="users.html", title="Users") @cherrypy.expose @@ -1100,7 +1100,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def user(self, user_id=None): + def user(self, user_id=None, **kwargs): if not allow_session_user(user_id): raise cherrypy.HTTPRedirect(plexpy.HTTP_ROOT) @@ -1566,7 +1566,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def history(self): + def history(self, **kwargs): return serve_template(templatename="history.html", title="History") @cherrypy.expose @@ -1740,7 +1740,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def graphs(self): + def graphs(self, **kwargs): config = { "graph_type": plexpy.CONFIG.GRAPH_TYPE, @@ -1753,7 +1753,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) - def set_graph_config(self, graph_type=None, graph_days=None, graph_tab=None): + def set_graph_config(self, graph_type=None, graph_days=None, graph_tab=None, **kwargs): if graph_type: plexpy.CONFIG.__setattr__('GRAPH_TYPE', graph_type) plexpy.CONFIG.write() @@ -2203,7 +2203,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def sync(self): + def sync(self, **kwargs): return serve_template(templatename="sync.html", title="Synced Items") @cherrypy.expose @@ -2229,7 +2229,7 @@ class WebInterface(object): ##### Logs ##### @cherrypy.expose @requireAuth(member_of("admin")) - def logs(self): + def logs(self, **kwargs): return serve_template(templatename="logs.html", title="Log") @cherrypy.expose @@ -2443,7 +2443,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def delete_logs(self): + def delete_logs(self, **kwargs): log_file = logger.FILENAME try: open(os.path.join(plexpy.CONFIG.LOG_DIR, log_file), 'w').close() @@ -2459,7 +2459,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) - def toggleVerbose(self): + def toggleVerbose(self, **kwargs): plexpy.VERBOSE = not plexpy.VERBOSE logger.initLogger(console=not plexpy.QUIET, log_dir=plexpy.CONFIG.LOG_DIR, verbose=plexpy.VERBOSE) @@ -2469,7 +2469,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def log_js_errors(self, page, message, file, line): + def log_js_errors(self, page, message, file, line, **kwargs): """ Logs javascript errors from the web interface. """ logger.error(u"WebUI :: /%s : %s. (%s:%s)" % (page.rpartition('/')[-1], message, @@ -2479,7 +2479,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) - def logFile(self): + def logFile(self, **kwargs): try: with open(os.path.join(plexpy.CONFIG.LOG_DIR, logger.FILENAME), 'r') as f: return '
    %s
    ' % f.read() @@ -2764,7 +2764,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def backup_config(self): + def backup_config(self, **kwargs): """ Creates a manual backup of the plexpy.db file """ result = config.make_backup() @@ -2787,7 +2787,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def get_server_update_params(self): + def get_server_update_params(self, **kwargs): plex_tv = plextv.PlexTV() plexpass = plex_tv.get_plexpass_status() return {'plexpass': plexpass, @@ -2800,7 +2800,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def backup_db(self): + def backup_db(self, **kwargs): """ Creates a manual backup of the plexpy.db file """ result = database.make_backup() @@ -2814,7 +2814,7 @@ class WebInterface(object): @cherrypy.tools.json_out() @requireAuth(member_of("admin")) @addtoapi() - def install_geoip_db(self): + def install_geoip_db(self, **kwargs): """ Downloads and installs the GeoLite2 database """ result = helpers.install_geoip_db() @@ -2828,7 +2828,7 @@ class WebInterface(object): @cherrypy.tools.json_out() @requireAuth(member_of("admin")) @addtoapi() - def uninstall_geoip_db(self): + def uninstall_geoip_db(self, **kwargs): """ Uninstalls the GeoLite2 database """ result = helpers.uninstall_geoip_db() @@ -2958,14 +2958,14 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) - def facebookStep1(self): + def facebookStep1(self, **kwargs): cherrypy.response.headers['Cache-Control'] = "max-age=0,no-cache,no-store" facebook = notifiers.FacebookNotifier() return facebook._get_authorization() @cherrypy.expose @requireAuth(member_of("admin")) - def facebookStep2(self, code): + def facebookStep2(self, code, **kwargs): cherrypy.response.headers['Cache-Control'] = "max-age=0,no-cache,no-store" facebook = notifiers.FacebookNotifier() result = facebook._get_credentials(code) @@ -2977,7 +2977,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) - def osxnotifyregister(self, app): + def osxnotifyregister(self, app, **kwargs): cherrypy.response.headers['Cache-Control'] = "max-age=0,no-cache,no-store" from osxnotify import registerapp as osxnotify @@ -3175,20 +3175,20 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) - def generateAPI(self): + def generateAPI(self, **kwargs): apikey = hashlib.sha224(str(random.getrandbits(256))).hexdigest()[0:32] logger.info(u"New API key generated.") return apikey @cherrypy.expose @requireAuth(member_of("admin")) - def checkGithub(self): + def checkGithub(self, **kwargs): versioncheck.checkGithub() raise cherrypy.HTTPRedirect(plexpy.HTTP_ROOT + "home") @cherrypy.expose @requireAuth(member_of("admin")) - def do_state_change(self, signal, title, timer): + def do_state_change(self, signal, title, timer, **kwargs): message = title quote = self.random_arnold_quotes() plexpy.SIGNAL = signal @@ -3198,17 +3198,17 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) - def shutdown(self): + def shutdown(self, **kwargs): return self.do_state_change('shutdown', 'Shutting Down', 15) @cherrypy.expose @requireAuth(member_of("admin")) - def restart(self): + def restart(self, **kwargs): return self.do_state_change('restart', 'Restarting', 30) @cherrypy.expose @requireAuth(member_of("admin")) - def update(self): + def update(self, **kwargs): return self.do_state_change('update', 'Updating', 120) @@ -3331,7 +3331,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth(member_of("admin")) @addtoapi() - def download_log(self): + def download_log(self, **kwargs): """ Download the PlexPy log file. """ log_file = logger.FILENAME try: @@ -3369,7 +3369,7 @@ class WebInterface(object): @cherrypy.tools.json_out() @requireAuth(member_of("admin")) @addtoapi() - def delete_image_cache(self): + def delete_image_cache(self, **kwargs): """ Delete and recreate the image cache directory. """ return self.delete_cache(folder='images') @@ -3377,7 +3377,7 @@ class WebInterface(object): @cherrypy.tools.json_out() @requireAuth(member_of("admin")) @addtoapi() - def delete_cache(self, folder=''): + def delete_cache(self, folder='', **kwargs): """ Delete and recreate the cache directory. """ cache_dir = os.path.join(plexpy.CONFIG.CACHE_DIR, folder) result = 'success' @@ -3404,7 +3404,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def delete_poster_url(self, poster_url=''): + def delete_poster_url(self, poster_url='', **kwargs): if poster_url: data_factory = datafactory.DataFactory() @@ -3422,7 +3422,7 @@ class WebInterface(object): @cherrypy.expose @requireAuth() - def search(self, query=''): + def search(self, query='', **kwargs): return serve_template(templatename="search.html", title="Search", query=query) @cherrypy.expose @@ -4284,7 +4284,7 @@ class WebInterface(object): @cherrypy.expose @cherrypy.tools.json_out() @requireAuth(member_of("admin")) - def check_pms_updater(self): + def check_pms_updater(self, **kwargs): pms_connect = pmsconnect.PmsConnect() result = pms_connect.get_update_staus() return result From 95ce293169cd7502e18161dc117326d684c47b3b Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Sat, 17 Sep 2016 15:15:33 -0700 Subject: [PATCH 08/13] Add FAQ link to dropdown --- data/interfaces/default/base.html | 1 + 1 file changed, 1 insertion(+) diff --git a/data/interfaces/default/base.html b/data/interfaces/default/base.html index 8cee62c5..b5eaa497 100644 --- a/data/interfaces/default/base.html +++ b/data/interfaces/default/base.html @@ -220,6 +220,7 @@
  • Settings
  • View Logs
  • +
  • PlexPy FAQ
  • Support
  • Paypal
  • From bce965b4024009fb849080be3931aa5bd8df6a1f Mon Sep 17 00:00:00 2001 From: Xus Badia Date: Sun, 18 Sep 2016 07:41:58 +0200 Subject: [PATCH 09/13] Fix for iPhone 6/7 Plus Changed the max-device-width from 400px to 450px so it adjusts to the iPhone 6/7 Plus screen and doesn't leave a gap on the right of the screen. --- data/interfaces/default/css/plexpy.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/interfaces/default/css/plexpy.css b/data/interfaces/default/css/plexpy.css index c608ebf9..9a18c04a 100644 --- a/data/interfaces/default/css/plexpy.css +++ b/data/interfaces/default/css/plexpy.css @@ -2662,7 +2662,7 @@ a .home-platforms-list-cover-face:hover @media only screen and (min-device-width: 300px) - and (max-device-width: 400px) { + and (max-device-width: 450px) { .home-platforms-instance { width: calc(100% - 20px); } From 465add46d44fbd4f659e7c6189db840be035b238 Mon Sep 17 00:00:00 2001 From: spolyack Date: Sun, 18 Sep 2016 11:36:09 -0400 Subject: [PATCH 10/13] Attempt to verify the PID in an existing PID file before giving up. If the PID doesn't map to a running process, then we can simply ignore the presence of the PID file and overwrite it with the current (new) PID later. --- PlexPy.py | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/PlexPy.py b/PlexPy.py index 82a91808..903ce790 100755 --- a/PlexPy.py +++ b/PlexPy.py @@ -122,8 +122,21 @@ def main(): # If the pidfile already exists, plexpy may still be running, so # exit if os.path.exists(plexpy.PIDFILE): - raise SystemExit("PID file '%s' already exists. Exiting." % - plexpy.PIDFILE) + try: + with open(plexpy.PIDFILE, 'r') as fp: + pid = int(fp.read()) + os.kill(pid, 0) + except IOError as e: + raise SystemExit("Unable to read PID file: %s", e) + except OSError: + logger.warn("PID file '%s' already exists, but PID %d is " \ + "not running. Ignoring PID file." % + (plexpy.PIDFILE, pid)) + else: + # The pidfile exists and points to a live PID. plexpy may + # still be running, so exit. + raise SystemExit("PID file '%s' already exists. Exiting." % + plexpy.PIDFILE) # The pidfile is only useful in daemon mode, make sure we can write the # file properly From 039b51262d103d151b65f360d0ed690e2d7896a3 Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Sun, 18 Sep 2016 21:06:44 -0700 Subject: [PATCH 11/13] Update readme --- CONTRIBUTING.md | 10 +++++----- README.md | 18 +++++++++--------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b0c6a04b..6b5e9643 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -9,14 +9,14 @@ In case you read this because you are posting an issue, please take a minute and - Turning your device off and on again. - Analyzing your logs, you just might find the solution yourself! - Using the **search** function to see if this issue has already been reported/solved. -- Checking the [Wiki](https://github.com/drzoidberg33/plexpy/wiki) for -[ [Installation] ](https://github.com/drzoidberg33/plexpy/wiki/Installation) and -[ [FAQs] ](https://github.com/drzoidberg33/plexpy/wiki/Frequently-Asked-Questions-(FAQ)). -- For basic questions try asking on [Gitter](https://gitter.im/drzoidberg33/plexpy) or the [Plex Forums](https://forums.plex.tv/discussion/169591/plexpy-another-plex-monitoring-program) first before opening an issue. +- Checking the [Wiki](https://github.com/JonnyWong16/plexpy/wiki) for +[ [Installation] ](https://github.com/JonnyWong16/plexpy/wiki/Installation) and +[ [FAQs] ](https://github.com/JonnyWong16/plexpy/wiki/Frequently-Asked-Questions-(FAQ)). +- For basic questions try asking on [Gitter](https://gitter.im/plexpy/general) or the [Plex Forums](https://forums.plex.tv/discussion/169591/plexpy-another-plex-monitoring-program) first before opening an issue. ##### If nothing has worked: -1. Open a new issue on the GitHub [issue tracker](http://github.com/drzoidberg33/plexpy/issues). +1. Open a new issue on the GitHub [issue tracker](http://github.com/JonnyWong16/plexpy/issues). 2. Provide a clear title to easily help identify your problem. 3. Use proper [markdown syntax](https://help.github.com/articles/github-flavored-markdown) to structure your post (i.e. code/log in code blocks). 4. Make sure you provide the following information: diff --git a/README.md b/README.md index 6bebbb64..bdc5c773 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,13 @@ # PlexPy -[![Join the chat at https://gitter.im/drzoidberg33/plexpy](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/drzoidberg33/plexpy?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) +[![Join the chat at https://gitter.im/plexpy/general](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/plexpy/general?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) A python based web application for monitoring, analytics and notifications for [Plex Media Server](https://plex.tv). This project is based on code from [Headphones](https://github.com/rembo10/headphones) and [PlexWatchWeb](https://github.com/ecleese/plexWatchWeb). * [Plex forum thread](https://forums.plex.tv/discussion/169591/plexpy-another-plex-monitoring-program) -* [Gitter chat](https://gitter.im/drzoidberg33/plexpy) +* [Gitter chat](https://gitter.im/plexpy/general) * [/r/Plex Discord server](https://discord.gg/011TFFWSuNFI02EKr) | [PlexPy Discord server](https://discord.gg/36ggawe) ## Features @@ -35,8 +35,8 @@ This project is based on code from [Headphones](https://github.com/rembo10/headp ## Installation and Support -* [Installation Guides](https://github.com/drzoidberg33/plexpy/wiki/Installation) shows you how to install PlexPy. -* [FAQs](https://github.com/drzoidberg33/plexpy/wiki/Frequently-Asked-Questions-(FAQ)) in the wiki can help you with common problems. +* [Installation Guides](https://github.com/JonnyWong16/plexpy/wiki/Installation) shows you how to install PlexPy. +* [FAQs](https://github.com/JonnyWong16/plexpy/wiki/Frequently-Asked-Questions-(FAQ)) in the wiki can help you with common problems. **Support** the project by implementing new features, solving support tickets and provide bug fixes. @@ -48,14 +48,14 @@ This project is based on code from [Headphones](https://github.com/rembo10/headp - Turning your device off and on again. - Analyzing your logs, you just might find the solution yourself! - Using the **search** function to see if this issue has already been reported/solved. -- Checking the [Wiki](https://github.com/drzoidberg33/plexpy/wiki) for -[ [Installation] ](https://github.com/drzoidberg33/plexpy/wiki/Installation) and -[ [FAQs] ](https://github.com/drzoidberg33/plexpy/wiki/Frequently-Asked-Questions-(FAQ)). -- For basic questions try asking on [Gitter](https://gitter.im/drzoidberg33/plexpy) or the [Plex Forums](https://forums.plex.tv/discussion/169591/plexpy-another-plex-monitoring-program) first before opening an issue. +- Checking the [Wiki](https://github.com/JonnyWong16/plexpy/wiki) for +[ [Installation] ](https://github.com/JonnyWong16/plexpy/wiki/Installation) and +[ [FAQs] ](https://github.com/JonnyWong16/plexpy/wiki/Frequently-Asked-Questions-(FAQ)). +- For basic questions try asking on [Gitter](https://gitter.im/plexpy/general) or the [Plex Forums](https://forums.plex.tv/discussion/169591/plexpy-another-plex-monitoring-program) first before opening an issue. ##### If nothing has worked: -1. Open a new issue on the GitHub [issue tracker](http://github.com/drzoidberg33/plexpy/issues). +1. Open a new issue on the GitHub [issue tracker](http://github.com/JonnyWong16/plexpy/issues). 2. Provide a clear title to easily help identify your problem. 3. Use proper [markdown syntax](https://help.github.com/articles/github-flavored-markdown) to structure your post (i.e. code/log in code blocks). 4. Make sure you provide the following information: From 51c9aa2887e9696ea6d416a44206c60b8a9c41bb Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Sun, 18 Sep 2016 21:58:44 -0700 Subject: [PATCH 12/13] Update FreeBSD service script --- init-scripts/init.freebsd | 22 ++++++++++++++++------ init-scripts/init.freenas | 2 +- 2 files changed, 17 insertions(+), 7 deletions(-) diff --git a/init-scripts/init.freebsd b/init-scripts/init.freebsd index 2cfb472f..69afbd08 100755 --- a/init-scripts/init.freebsd +++ b/init-scripts/init.freebsd @@ -49,23 +49,33 @@ fi verify_plexpy_pid() { # Make sure the pid corresponds to the PlexPy process. - pid=`cat ${plexpy_pid} 2>/dev/null` - ps -p ${pid} | grep -q "python ${plexpy_dir}/PlexPy.py" - return $? + if [ -f ${plexpy_pid} ]; then + pid=`cat ${plexpy_pid} 2>/dev/null` + ps -p ${pid} | grep -q "python2 ${plexpy_dir}/PlexPy.py" + return $? + else + return 0 + fi } -# Try to stop PlexPy cleanly by calling shutdown over http. +# Try to stop PlexPy cleanly by sending SIGTERM plexpy_stop() { echo "Stopping $name" verify_plexpy_pid if [ -n "${pid}" ]; then + kill ${pid} wait_for_pids ${pid} - echo "Stopped" + echo "Stopped." fi } plexpy_status() { - verify_plexpy_pid && echo "$name is running as ${pid}" || echo "$name is not running" + verify_plexpy_pid + if [ -n "${pid}" ]; then + echo "$name is running as ${pid}." + else + echo "$name is not running." + fi } run_rc_command "$1" diff --git a/init-scripts/init.freenas b/init-scripts/init.freenas index c19b824b..f708c85e 100755 --- a/init-scripts/init.freenas +++ b/init-scripts/init.freenas @@ -58,7 +58,7 @@ verify_plexpy_pid() { fi } -# Try to stop PlexPy cleanly by calling shutdown over http. +# Try to stop PlexPy cleanly by sending SIGTERM plexpy_stop() { echo "Stopping $name." verify_plexpy_pid From 47de9a752cf253d67624bee79d1255a38f33aca4 Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Sun, 18 Sep 2016 22:11:12 -0700 Subject: [PATCH 13/13] v1.4.12 --- CHANGELOG.md | 11 +++++++++++ data/interfaces/default/base.html | 2 +- plexpy/version.py | 2 +- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fabe94f2..4424b7f6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,16 @@ # Changelog +## v1.4.12 (2016-09-18) + +* Fix: PMS update check not working for MacOSX. +* Fix: Square covers for music stats on homepage. +* Fix: Card width on the homepage for iPhone 6/7 Plus. (Thanks @XusBadia) +* Fix: Check for running PID when starting PlexPy. (Thanks @spolyack) +* Fix: FreeBSD service script not stopping PlexPy properly. +* Fix: Some web UI cleanup. +* Change: GitHub repostitory moved. + + ## v1.4.11 (2016-09-02) * Fix: PlexWatch and Plexivity import errors. diff --git a/data/interfaces/default/base.html b/data/interfaces/default/base.html index b5eaa497..baaab0ee 100644 --- a/data/interfaces/default/base.html +++ b/data/interfaces/default/base.html @@ -220,7 +220,7 @@
  • Settings
  • View Logs
  • -
  • PlexPy FAQ
  • +
  • FAQ
  • Support
  • Paypal
  • diff --git a/plexpy/version.py b/plexpy/version.py index 4ba5caf9..9c1b9956 100644 --- a/plexpy/version.py +++ b/plexpy/version.py @@ -1,2 +1,2 @@ PLEXPY_VERSION = "master" -PLEXPY_RELEASE_VERSION = "1.4.11" +PLEXPY_RELEASE_VERSION = "1.4.12"
    + Plex Update Available
    Git Branch:${plexpy.CONFIG.GIT_BRANCH}${plexpy.CONFIG.GIT_BRANCH}
    Git Commit Hash:${plexpy.CURRENT_VERSION}${plexpy.CURRENT_VERSION}
    Resources: - GitHub Source | - GitHub Issues | - FeatHub Feature Requests | - PlexPy Wiki | - PlexPy FAQ + GitHub Source | + GitHub Issues | + FeatHub Feature Requests | + PlexPy Wiki | + PlexPy FAQ
    Support: Plex Forums | - PlexPy Gitter Chat | + PlexPy Gitter Chat | /r/Plex Discord Server | PlexPy Discord Server