plexWatch - Windows Branch

I'm trying to get the IP logging enabled, but keep getting the error that it doesn't exist. Something I'm forgetting?

$server_log = 'c:\\Users\\hermanna\\AppData\\Local\\Plex Media Server\\Plex Media Server.log'; ## used to log IP address of user (alpha)
$log_client_ip = 1; ## requires $server_log to be available too. (requires File::ReadBackwards)
 


Also, watched/watching push notifications work fine, but recently added don't, even though it's enabled. Is there anything other then the Pushover config part I need to configure for this to work?

'push_watching'       => 1,
 

I am not sure about the IP. Can you post the error the script outputs?

Also, I have push a new up - https://github.com/ljunkie/plexWatch/tree/v0.0.19-2-win32 (zip). It now includes the vbs script you should use to run the scheduled tasks.

Automatically notify on watching/watched content: 

* schedule a task (every minute) to execute c:\plexWatch\plexWatchNotify.vbs  ( specify the start in folder as c:\plexWatch\

 

Automatically notify on Recently Added Content:

* schedule a task (every 5 minutes or more) to execute c:\plexWatch\plexWatchRecentlyAdded.vbs  ( specify the start in folder as c:\plexWatch\

I was about to start writing my own solution for this, I'm so glad I came across this!

Quick question - is the database automatically rotated or will it just keep expanding?

I'd like to build some reporting around the SQLLite DB, but I want to make sure it won't lose all of it's data at some point.

Thanks for your work on this!!!

The DB is never expunged automatically. The script will also keep a couple backups of the DB just in case something bad happens. 

I have quite a few changes/fixes/mods in the linux version and I believe it's been stable enough to try and release. This mean I will be trying to build the windows version shortly.

Thank you for the appreciation

ps. A fellow community member is already working on a web front end that looks pretty amazing. I am not sure when he is going to release it, but it's definitely looking good!

I seem to be missing something here, perhaps my PLEX Server wasn't installed correctly.

I get this error when trying to run plexWatch.exe

Failed to get request http://localhost:32400/status/sessions - The result:
Not Found

404 Not Found

The server is hosted on this machine and the port is set to 32400. Any help would be appreciated!

I seem to be missing something here, perhaps my PLEX Server wasn't installed correctly.

I get this error when trying to run plexWatch.exe

Failed to get request http://localhost:32400/status/sessions - The result:
Not Found

404 Not Found

The server is hosted on this machine and the port is set to 32400. Any help would be appreciated!

You must be a PlexPass Subscriber for the now playing to work.

Edit: I see you are. Make sure you have 0.9.8.6+ installed and you are logged into your Plex server with your PlexPass username. 

You must be a PlexPass Subscriber for the now playing to work.

Edit: I see you are. Make sure you have 0.9.8.6+ installed and you are logged into your Plex server with your PlexPass username. 

Doh! I found it. I was on version 9.7.28

Thanks for the help!

Cant wait for that web frontend, looks really sleek.

Also, are there any plans for implementing Twitter support for Windows?

Also, are there any plans for implementing Twitter support for Windows?


I can take another look to see if the twitter modules have been fixe upstream. I've been slammed with rarflix, but I need to merge my linux dev to release and then build a windows version. I will note to look into the twitter code when I do that.

Saved! Thanks!

I have this installed and functioning with my Plex windows server. I have not set it up with the IP Logging as of yet. I need to look into how to do that a bit more, but if there's ever anything I can do to help test, feel free to ask, I'd be more than welcome to help.

And that Web Front-End looks sweet! Great job by whoever is working on that. I hope we'll be able to make use of it with the Windows implementation too. :)

I have this installed and functioning with my Plex windows server. I have not set it up with the IP Logging as of yet. I need to look into how to do that a bit more, but if there's ever anything I can do to help test, feel free to ask, I'd be more than welcome to help.

And that Web Front-End looks sweet! Great job by whoever is working on that. I hope we'll be able to make use of it with the Windows implementation too. :)

Where do you see the web front end mentioned? 

I know this might sound stupid, but I'm thinking, people are getting confused and there is a lack of understanding. People don't want to mess up their current setup. Perhaps someone could make a quick youtube video and voice narrate. Also, if someone does do this 2 things. I read in this thread they were getting pushover notifications. I would be looking for a way to integrate pushover, or perhaps another android app for monitoring. Lastly, permission to use said video on my website.

Where do you see the web front end mentioned? 

It was posted in a somewhat related topic in one of the PlexPass forums.

http://forums.plexapp.com/index.php/topic/46451-very-popular-show-who-is-streaming-what-and-when/?p=471396

Announcement : plexWatch Linux v0.1.0 Released

This means I will now be looking into compiling a windows version. 

Looking forward to it!

PlexWatch v0.1.1 Released

 
Downloads: plexWatch.exe and config.pl-dist-win32

GitHub: https://github.com/ljunkie/plexWatch/tree/dev (source: plexWatch.pl )

Screenshots: iOS Boxcar // iOS Prowl // iOS Pushover // Win7 Growl
 
Make sure you look at the new config.pl-dist-win32 ( old config.pl will work, but you will probably want to update the two things I list below )

Things to update in your config.pl 
 
1) $alert_format -- I would use these ongoing and change them as your see fit. Mainly removing "{user} watched|watching|etc" from the beginning - The title is dynamically corrected now to to fix redundancy  

$alert_format = {'start'    => '{title} [{streamtype}] [{year}] [{rating}] on {platform} [{progress} in] {ip_address}',
                 'paused'   => '{title} [{streamtype}] [{year}] [{rating}] on {platform} [{progress} in] [{percent_complete}%] {ip_address}',
                 'resumed'  => '{title} [{streamtype}] [{year}] [{rating}] on {platform} [{progress} in] [{percent_complete}%] {ip_address}',
                 'stop'     => '{title} [{streamtype}] [{year}] [{rating}] on {platform} for {duration} [{percent_complete}%] {ip_address}',
                 'watched'  => '{user} watched {title} [{streamtype}] [{year}] [{length}] [{rating}] on {platform} for {duration} [{percent_complete}%] {ip_address}',
                 'watching' => '{user} {state} {title} [{streamtype}] [{year}] [{rating}] [{length}] on {platform} for {duration} [{percent_complete}%] [{time_left} left] {ip_address}'
                 };

 
2) $notify  -- added new new push options to every provider ( except file of course )

'push_paused' => 1,
'push_resumed' => 1,

Change Log  0.1.0

* Twitter now works for windows

* Linux and Windows branches (dev) are now on the same code base.

 
Change Log  0.1.0
 
 * NEW: Email provider ( NonAuth, Auth, TLS/SSL supported) requires Net::SMTP::TLS
         centos: yum install perl\(Net::SMTP::TLS\)
         debian: apt-get install libnet-smtp-tls-perl
         other: cpan install MIME::Lite
 * NEW: paused/resumed state and time are now accounted for
 * NEW: paused/resumed push types enabled - push_paused, pushed_resumed added to each provider
 * NEW: you can override 'alert_format' per provider ( check out the EMAIL provider for an example )
 

 * FIX: watched duration corrected going forward (accounts for paused content and can be overridden with $count_paused )
         paused/resumed states have allowed this to work
 * FIX: Redundant titles are now fixed         - Title/Application also will always show {user} unless overridden in config.pl
         $appname is no longer used and replaced with {user} -- {user} if used even if config.pl has $appname ( no need to update config.pl )
         before:  title: "plexWatch watched" msg: "user watched title etc...."
          after:  title: "{user} watched"    msg: "title etc...."
 * FIX: --test_notify will not print options to test ( and they actually correspond to the right notification type now!)
 * FIX: do not print backup info every time --debug is called
 * FIX: duration watched when video is paused, then stopped
 * FIX: XML UTF-8 decoding/encoding ( only seemd to affect FC18 ) 
 * FIX: Accent marks/umlauts are allowed 

 * Screenshots added to screenshots folder for iOS and Windows
 
 
 
 

I've successfully updated, Resume/Paused works fine - Still not getting Twitter to work though. I see the 'application'         => $appname, line has been removed in the new configuration file, is that not something that is needed?

EDIT: One bug that I notice almost instantly, everytime plexWatch.exe is run, it notifies me of paused Items. That's going to fill my pushover notifications bar, with 3-4 users perhaps with their playback paused. Would be nice if it could be limited to 1 notification per file/stream. 

I've successfully updated, Resume/Paused works fine - Still not getting Twitter to work though. I see the 'application'         => $appname, line has been removed in the new configuration file, is that not something that is needed?

EDIT: One bug that I notice almost instantly, everytime plexWatch.exe is run, it notifies me of paused Items. That's going to fill my pushover notifications bar, with 3-4 users perhaps with their playback paused. Would be nice if it could be limited to 1 notification per file/stream. 

Yep, application was not even used - so that shouldn't be affecting it. I have verified it work here. That is the only reason I mentioned it was fixed :)

here is my config - minus my keys of course ( note I only push on recently added content, others will work though )

* you can test it with ./plexWatch --test_nofity=recent

'twitter' => {
    'enabled'             => 1, ## set to 1 to enable local growl
    'push_recentlyadded'  => 1,
    'push_watched'        => 0,
    'push_watching'       => 0,
    'push_paused'         => 0,
    'push_resumed'        => 0,
    'title'               => '{user}',
    'consumer_key'        => 'removed',
    'consumer_secret'     => 'removed',
    'access_token'        => 'removed',
    'access_token_secret' => 'removed',
    'alert_format' => {
        'start'    =>  '{title} [{streamtype}] [{year}] [{rating}] on {platform} [{progress} in]',
        'paused'   =>  '{title} [{streamtype}] [{year}] [{rating}] on {platform} [{progress} in] [{percent_complete}%]',
        'resumed'  =>  '{title} [{streamtype}] [{year}] [{rating}] on {platform} [{progress} in] [{percent_complete}%]',
        'stop'     =>  '{title} [{streamtype}] [{year}] [{rating}] on {platform} for {duration} [{percent_complete}%]',
    },
},

I will respond to you second "issue" in another reply. 

EDIT: One bug that I notice almost instantly, everytime plexWatch.exe is run, it notifies me of paused Items. That's going to fill my pushover notifications bar, with 3-4 users perhaps with their playback paused. Would be nice if it could be limited to 1 notification per file/stream. 

I wouldn't call that a "bug" and I am not sure you are understanding what it does correctly.  It's showing you exactly what the end user is doing. It will only notify once if a user was playing an item, and them they pause it. It will not continue to notify if the user keeps it paused. It will also notify on the resume if of course you have push_resumed enabled.