SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Customizations

Notices

SageTV Customizations This forums is for discussing and sharing user-created modifications for the SageTV application created by using the SageTV Studio or through the use of external plugins. Use this forum to discuss customizations for SageTV version 6 and earlier, or for the SageTV3 UI.

Closed Thread
 
Thread Tools Search this Thread Display Modes
  #61  
Old 06-15-2008, 08:41 PM
toricred's Avatar
toricred toricred is offline
Sage Icon
 
Join Date: Jan 2006
Location: Northern New Mexico
Posts: 1,719
I tried that and it still tried to process .avi files. It also seems to be ignoring my setting for ignoring channel numbers 500-599 and files with .edl files already. I'm going to do more troubleshooting tomorrow. I'm a little frustrated at this point and I know I must be just missing something.
  #62  
Old 06-15-2008, 09:26 PM
toricred's Avatar
toricred toricred is offline
Sage Icon
 
Join Date: Jan 2006
Location: Northern New Mexico
Posts: 1,719
I think I've found the problem. I didn't realize that every time I changed the rules I needed to restart the web server (in my case the service on the server). Once I did that the rules started working as written.
  #63  
Old 06-15-2008, 09:46 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by toricred View Post
OK, I used a command line to get SA to not throttle.

It turns out that it still isn't looking at only .mpg files so I'm trying a different rule as follows:

% Filename: *.mpg
The Filename test already has debug data in it so if you go to the log viewer and look at a file that passed when it should, the log should say why it passed. That's the data I need along with the rule file used during the run.
  #64  
Old 06-15-2008, 09:48 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by toricred View Post
I think I've found the problem. I didn't realize that every time I changed the rules I needed to restart the web server (in my case the service on the server). Once I did that the rules started working as written.
This is not true... or it shouldn't be. SJQ reads (or is suppose to read) the rule file before each run. I can't reproduce this behaviour. I edit the rule file and rerun and it reads the updated ruleset each time.

EDIT: But if you're editing the rules via the servlet you need to click "Save Rule" after making any changes before they take effect. And you definitely don't need to restart Sage/SJQ for rule changes to take effect or at least I can't reproduce that behaviour at all - I've tried everything I can think of to reproduce that and I can't. Edits to the rules are used immediately on the next run of SJQ. I'm using v1.4.0 (latest available).

Last edited by Slugger; 06-15-2008 at 09:56 PM.
  #65  
Old 06-15-2008, 10:04 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by nyplayer View Post
Slugger,

Is it possible to add a rule..if the Show Is Archived? I would like to move a show to a different drive if it is Archived.
Feature request opened. I'll implement it sometime this week and it'll appear in the 1.5.0 release. Not sure when exactly that release will come as there are a few other things I want to include in the next release, but I find myself spending much less time playing with the PVR in the summer months. If you really want this test then PM later in the week and I can ship you an updated jar file with the test included in it.
  #66  
Old 06-16-2008, 07:07 PM
toricred's Avatar
toricred toricred is offline
Sage Icon
 
Join Date: Jan 2006
Location: Northern New Mexico
Posts: 1,719
I figured out why I had to stop and restart Sage. I had set SJQ to run continuously. So it never started a new job.
  #67  
Old 06-19-2008, 08:47 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
In case anyone else is interested in the IsArchived test, here's a 1.5.0 beta build that includes the test. I labeled this build a "beta" but the only change between 1.4.0 and this build is the addition of the IsArchived test so I'd consider this version to be quite stable, should you need/want the IsArchived test.

I have no plans to do any serious coding in the next little while so it's probably going to be awhile before the official 1.5.0 build is released with this new test included in it.
  #68  
Old 06-27-2008, 02:18 PM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 3,987
Slugger,

Any reason this doesnt' work If i set up a job for each title individually it works. If I put 2 Titles on 1 job it doesn't even run.

###__SetManRecStatus3
= IsManualRecord: false
= Title: Dark Angel | Buffy the Vampire Slayer
= IsActivelyRecording: false
RunSetManRecStatusED "\\janedserver\sageencode\SetManRecStatus.bat" "%f%"
__________________
Windows 10 I3 Dual Core 3.0 Server, SageTV9... OpenDCT with 2 HDHRPrimes and 4 HDHRconnects for a total of 14 Tuners.
  #69  
Old 06-27-2008, 04:01 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by nyplayer View Post
Slugger,

Any reason this doesnt' work If i set up a job for each title individually it works. If I put 2 Titles on 1 job it doesn't even run.

###__SetManRecStatus3
= IsManualRecord: false
= Title: Dark Angel | Buffy the Vampire Slayer
= IsActivelyRecording: false
RunSetManRecStatusED "\\janedserver\sageencode\SetManRecStatus.bat" "%f%"
I'll assume by "doesn't even run" you mean that it runs, but never matches. If SJQ is crashing then I'd really like some log output to track that down.

It doesn't match because the test your using is equality - so as defined here, you're actually looking for a title that equals "Dark Angel | Buffy the Vampire Slayer", which obviously doesn't exist. You could use a regular expression instead to do what you're trying to do. Sub the line as follows:

% Title: Dark Angel|Buffy the Vampire Slayer

Important to note that you can't have white space between the | character. That should work (however, it's untested, off the top of my head). Basically, use a regular expression instead of the straight string equality test to do "fancy" things like this.
  #70  
Old 06-27-2008, 04:30 PM
toricred's Avatar
toricred toricred is offline
Sage Icon
 
Join Date: Jan 2006
Location: Northern New Mexico
Posts: 1,719
When checking for strings starting, contains, etc. or regular expression, does case matter? Is there a way to stop it from mattering if it does?
  #71  
Old 06-27-2008, 04:41 PM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 3,987
Thank you... Slugger that was the case. Regular expression worked.

Quote:
Originally Posted by Slugger View Post
I'll assume by "doesn't even run" you mean that it runs, but never matches. If SJQ is crashing then I'd really like some log output to track that down.

It doesn't match because the test your using is equality - so as defined here, you're actually looking for a title that equals "Dark Angel | Buffy the Vampire Slayer", which obviously doesn't exist. You could use a regular expression instead to do what you're trying to do. Sub the line as follows:

% Title: Dark Angel|Buffy the Vampire Slayer

Important to note that you can't have white space between the | character. That should work (however, it's untested, off the top of my head). Basically, use a regular expression instead of the straight string equality test to do "fancy" things like this.
__________________
Windows 10 I3 Dual Core 3.0 Server, SageTV9... OpenDCT with 2 HDHRPrimes and 4 HDHRconnects for a total of 14 Tuners.
  #72  
Old 06-27-2008, 06:37 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by toricred View Post
When checking for strings starting, contains, etc. or regular expression, does case matter? Is there a way to stop it from mattering if it does?
Yes, the tests are case sensitive. No, there is no way to change that (at this time). If it's something you need/want then feel free to open a feature request and I'll see what can be done.
  #73  
Old 07-01-2008, 12:37 PM
madas madas is offline
Sage Advanced User
 
Join Date: Jun 2008
Posts: 83
Any ideas why i get this?

Processing media object: 'Reading Rainbow'
Checking if media object '1177528' has been processed by action type 'COMMFLAG'
SELECT COUNT(*) FROM recordings WHERE id = 1177528 AND type = 'COMMFLAG'
Executing action line as all tests for rule 0 returned true
Running: [C:\Program Files\SageTv\Comskip\ComSkip.exe, C:\Media\Sage\ReadingRainbow-DesertGiant-714150-0.mpg]
Comskip 0.79.140, made using:
comskip-0.4.1-cvs - by Michel Lespinasse and Aaron Holtzman
0:00:10 - 304 frames in 1.00 sec (304.00 fps), 1.00 sec (304.00 fps), 7%
0:00:21 - 633 frames in 1.99 sec (318.09 fps), 1.00 sec (329.00 fps), 15%
0:00:25 - 771 frames in 2.99 sec (257.86 fps), 1.00 sec (138.00 fps), 18%
0:00:31 - 957 frames in 3.98 sec (240.45 fps), 1.00 sec (186.00 fps), 22%
0:00:39 - 1196 frames in 4.97 sec (240.64 fps), 1.00 sec (239.00 fps), 28%
0:00:42 - 1291 frames in 5.97 sec (216.25 fps), 1.00 sec (95.00 fps), 30%
0:00:49 - 1483 frames in 6.96 sec (213.07 fps), 1.00 sec (192.00 fps), 35%
0:00:56 - 1699 frames in 7.96 sec (213.44 fps), 1.00 sec (216.00 fps), 40%
0:00:59 - 1798 frames in 8.95 sec (200.89 fps), 1.00 sec (99.00 fps), 42%
0:01:10 - 2129 frames in 9.95 sec (213.97 fps), 1.00 sec (331.00 fps), 50%
0:01:14 - 2243 frames in 10.94 sec (205.03 fps), 1.00 sec (114.00 fps), 53%
0:01:21 - 2456 frames in 11.94 sec (205.70 fps), 1.00 sec (213.00 fps), 58%
0:01:25 - 2556 frames in 12.94 sec (197.53 fps), 1.00 sec (100.00 fps), 60%
0:01:27 - 2641 frames in 13.94 sec (189.45 fps), 1.00 sec (85.00 fps), 62%
0:01:30 - 2717 frames in 14.93 sec (181.98 fps), 1.00 sec (76.00 fps), 64%
0:01:34 - 2843 frames in 15.93 sec (178.47 fps), 1.00 sec (126.00 fps), 67%
0:01:39 - 2974 frames in 16.93 sec (175.66 fps), 1.00 sec (131.00 fps), 70%
0:01:41 - 3047 frames in 17.92 sec (170.03 fps), 1.00 sec (73.00 fps), 72%
0:01:43 - 3106 frames in 18.92 sec (164.16 fps), 1.00 sec (59.00 fps), 73%
0:01:45 - 3163 frames in 19.92 sec (158.79 fps), 1.00 sec (57.00 fps), 74%
0:01:46 - 3210 frames in 20.92 sec (153.44 fps), 1.00 sec (47.00 fps), 75%
0:01:52 - 3365 frames in 21.92 sec (153.51 fps), 1.00 sec (155.00 fps), 79%
0:01:55 - 3453 frames in 22.92 sec (150.65 fps), 1.00 sec (88.00 fps), 81%
0:01:57 - 3522 frames in 23.91 sec (147.30 fps), 1.00 sec (69.00 fps), 83%
0:01:59 - 3582 frames in 24.92 sec (143.74 fps), 1.00 sec (60.00 fps), 84%
0:02:01 - 3640 frames in 25.92 sec (140.43 fps), 1.00 sec (58.00 fps), 86%
0:02:03 - 3694 frames in 26.91 sec (137.27 fps), 1.00 sec (54.00 fps), 87%
0:02:09 - 3878 frames in 27.90 sec (139.00 fps), 1.00 sec (184.00 fps), 91%
0:02:11 - 3948 frames in 28.91 sec (136.56 fps), 1.00 sec (70.00 fps), 93%
0:02:13 - 4012 frames in 29.90 sec (134.18 fps), 1.00 sec (64.00 fps), 94%
0:02:15 - 4069 frames in 30.89 sec (131.73 fps), 1.00 sec (57.00 fps), 96%
0:02:17 - 4127 frames in 31.89 sec (129.41 fps), 1.00 sec (58.00 fps), 97%
0:02:19 - 4184 frames in 32.90 sec (127.17 fps), 1.00 sec (57.00 fps), 98%
0:02:20 - 4220 frames in 37.60 sec (112.23 fps), 4.70 sec (7.66 fps), 99%

4227 frames decoded in 37.64 seconds (112.30 fps)
The commandline used was:
"C:\Program Files\SageTv\Comskip\ComSkip.exe" C:\Media\Sage\ReadingRainbow-DesertGiant-714150-0.mpg

Opening C:\Media\Sage\ReadingRainbow-DesertGiant-714150-0.mpg
Using C:\Program Files\SageTv\Comskip\comskip.ini for initiation values.
Commercials were found.
Action failed! [Returned 1 to parent]


It seems to work ok. My rules file contains

= IsTV: true # Only run SA against recorded TV
= IsScheduledRecording: true # Ignore live tv and IR recordings
$ Filename: .mpg # Only run SA against MPEG2 recordings
= IsActivelyRecording: false # Wait until program is finished before scanning
COMMFLAG "C:\Program Files\SageTv\Comskip\ComSkip.exe" "%f%"
  #74  
Old 07-01-2008, 01:05 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by madas View Post
Any ideas why i get this?

Processing media object: 'Reading Rainbow'
Checking if media object '1177528' has been processed by action type 'COMMFLAG'
SELECT COUNT(*) FROM recordings WHERE id = 1177528 AND type = 'COMMFLAG'
Executing action line as all tests for rule 0 returned true
Running: [C:\Program Files\SageTv\Comskip\ComSkip.exe, C:\Media\Sage\ReadingRainbow-DesertGiant-714150-0.mpg]
Comskip 0.79.140, made using:
comskip-0.4.1-cvs - by Michel Lespinasse and Aaron Holtzman
0:00:10 - 304 frames in 1.00 sec (304.00 fps), 1.00 sec (304.00 fps), 7%
0:00:21 - 633 frames in 1.99 sec (318.09 fps), 1.00 sec (329.00 fps), 15%
0:00:25 - 771 frames in 2.99 sec (257.86 fps), 1.00 sec (138.00 fps), 18%
0:00:31 - 957 frames in 3.98 sec (240.45 fps), 1.00 sec (186.00 fps), 22%
0:00:39 - 1196 frames in 4.97 sec (240.64 fps), 1.00 sec (239.00 fps), 28%
0:00:42 - 1291 frames in 5.97 sec (216.25 fps), 1.00 sec (95.00 fps), 30%
0:00:49 - 1483 frames in 6.96 sec (213.07 fps), 1.00 sec (192.00 fps), 35%
0:00:56 - 1699 frames in 7.96 sec (213.44 fps), 1.00 sec (216.00 fps), 40%
0:00:59 - 1798 frames in 8.95 sec (200.89 fps), 1.00 sec (99.00 fps), 42%
0:01:10 - 2129 frames in 9.95 sec (213.97 fps), 1.00 sec (331.00 fps), 50%
0:01:14 - 2243 frames in 10.94 sec (205.03 fps), 1.00 sec (114.00 fps), 53%
0:01:21 - 2456 frames in 11.94 sec (205.70 fps), 1.00 sec (213.00 fps), 58%
0:01:25 - 2556 frames in 12.94 sec (197.53 fps), 1.00 sec (100.00 fps), 60%
0:01:27 - 2641 frames in 13.94 sec (189.45 fps), 1.00 sec (85.00 fps), 62%
0:01:30 - 2717 frames in 14.93 sec (181.98 fps), 1.00 sec (76.00 fps), 64%
0:01:34 - 2843 frames in 15.93 sec (178.47 fps), 1.00 sec (126.00 fps), 67%
0:01:39 - 2974 frames in 16.93 sec (175.66 fps), 1.00 sec (131.00 fps), 70%
0:01:41 - 3047 frames in 17.92 sec (170.03 fps), 1.00 sec (73.00 fps), 72%
0:01:43 - 3106 frames in 18.92 sec (164.16 fps), 1.00 sec (59.00 fps), 73%
0:01:45 - 3163 frames in 19.92 sec (158.79 fps), 1.00 sec (57.00 fps), 74%
0:01:46 - 3210 frames in 20.92 sec (153.44 fps), 1.00 sec (47.00 fps), 75%
0:01:52 - 3365 frames in 21.92 sec (153.51 fps), 1.00 sec (155.00 fps), 79%
0:01:55 - 3453 frames in 22.92 sec (150.65 fps), 1.00 sec (88.00 fps), 81%
0:01:57 - 3522 frames in 23.91 sec (147.30 fps), 1.00 sec (69.00 fps), 83%
0:01:59 - 3582 frames in 24.92 sec (143.74 fps), 1.00 sec (60.00 fps), 84%
0:02:01 - 3640 frames in 25.92 sec (140.43 fps), 1.00 sec (58.00 fps), 86%
0:02:03 - 3694 frames in 26.91 sec (137.27 fps), 1.00 sec (54.00 fps), 87%
0:02:09 - 3878 frames in 27.90 sec (139.00 fps), 1.00 sec (184.00 fps), 91%
0:02:11 - 3948 frames in 28.91 sec (136.56 fps), 1.00 sec (70.00 fps), 93%
0:02:13 - 4012 frames in 29.90 sec (134.18 fps), 1.00 sec (64.00 fps), 94%
0:02:15 - 4069 frames in 30.89 sec (131.73 fps), 1.00 sec (57.00 fps), 96%
0:02:17 - 4127 frames in 31.89 sec (129.41 fps), 1.00 sec (58.00 fps), 97%
0:02:19 - 4184 frames in 32.90 sec (127.17 fps), 1.00 sec (57.00 fps), 98%
0:02:20 - 4220 frames in 37.60 sec (112.23 fps), 4.70 sec (7.66 fps), 99%

4227 frames decoded in 37.64 seconds (112.30 fps)
The commandline used was:
"C:\Program Files\SageTv\Comskip\ComSkip.exe" C:\Media\Sage\ReadingRainbow-DesertGiant-714150-0.mpg

Opening C:\Media\Sage\ReadingRainbow-DesertGiant-714150-0.mpg
Using C:\Program Files\SageTv\Comskip\comskip.ini for initiation values.
Commercials were found.
Action failed! [Returned 1 to parent]


It seems to work ok. My rules file contains

= IsTV: true # Only run SA against recorded TV
= IsScheduledRecording: true # Ignore live tv and IR recordings
$ Filename: .mpg # Only run SA against MPEG2 recordings
= IsActivelyRecording: false # Wait until program is finished before scanning
COMMFLAG "C:\Program Files\SageTv\Comskip\ComSkip.exe" "%f%"
>> Action failed! [Returned 1 to parent]

This is the problem. Even though it appears comskip ran successfully (based on its output it suggests that it did), for some reason comskip decided to return a return code of 1 back to the caller, which in this case is SJQ. When SJQ gets a return code from a process that is non-zero then it interprets that as an error and assumes the program failed in some way. This is the standard way to interpret return codes from an executed program (zero means success and anything else means failure). So, you need to find out why comskip is returning non-zero and either fix the error/warning/etc. and make it return zero or create a wrapper script that calls it and returns zero to SJQ when comskip returns 1 (if an rc of 1 from comskip is indeed signifying success).

I'd pay a visit to the comskip site and try to first find out what an rc of 1 actually means. If by some chance it does signify success then I'd ask the author(s) to reconsider that return code and have it return 0 on success. If the rc means something like "success with warnings" or something then you'll need to address whatever warning it is issuing so it returns 0. SJQ will only consider a process successful if it receives an rc of 0 otherwise it assumes that the process failed and will not mark it as completed (and will run the process again on its next run).
  #75  
Old 07-01-2008, 01:18 PM
madas madas is offline
Sage Advanced User
 
Join Date: Jun 2008
Posts: 83
""""""""""""""""
Return Values

If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero. To get extended error information, call GetLastError.

"""""""""""""""""

So can I just wrap a batch file that has a

RETURN 0 at the end?
  #76  
Old 07-01-2008, 01:45 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by madas View Post
""""""""""""""""
Return Values

If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero. To get extended error information, call GetLastError.

"""""""""""""""""

So can I just wrap a batch file that has a

RETURN 0 at the end?
Yes, that would be the idea. Windows batch files aren't my expertise, so I'll leave the implementation details to you.

However, I would stress that you don't want to blindly return 0, but rather return 0 if comskip returns 1 and return 1 if comskip returns 0.

Even better, the author of comskip will flip their logic to follow the typical standard meaning of return codes, but until that happens, calling comskip from a batch file and then calling that batch file in SJQ would be the best work around.
  #77  
Old 07-01-2008, 01:57 PM
madas madas is offline
Sage Advanced User
 
Join Date: Jun 2008
Posts: 83
Here is an example just incase someone else needs it

"c:\program files\sagetv\comskip\comskip.exe" "%1"
IF "%errorlevel%"=="1" goto GOOD

exit /b 1

:GOOD
exit /b 0
  #78  
Old 07-01-2008, 07:15 PM
madas madas is offline
Sage Advanced User
 
Join Date: Jun 2008
Posts: 83
One other question.

If I use the transcode option, all of the information from the original show is copied over except the channel number. The channel number of the transcoded file appears blank.

Is this a bug in SJQ or Sage itself?

Thanks

M

P.S. SJQ is working great, extremely powerful!
  #79  
Old 07-01-2008, 07:45 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by madas View Post
One other question.

If I use the transcode option, all of the information from the original show is copied over except the channel number. The channel number of the transcoded file appears blank.

Is this a bug in SJQ or Sage itself?

Thanks

M

P.S. SJQ is working great, extremely powerful!
My initial thought is that it's a Sage bug, but I'll need you to clarify what you mean by "all of the info from the original show is copied except the channel number." Is this in the file name of the transcoded file or in the program details after the transcode is complete or something else completely?
  #80  
Old 07-01-2008, 11:07 PM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 3,987
Quote:
Originally Posted by madas View Post
One other question.

If I use the transcode option, all of the information from the original show is copied over except the channel number. The channel number of the transcoded file appears blank.

Is this a bug in SJQ or Sage itself?

Thanks

M

P.S. SJQ is working great, extremely powerful!
That is the way Sage works when it transcodes has nothing to do with SJQ. If you transcode a recording within SageTV you will not see the Channel #. I know if I use the webserver to transcode the same thing happens no channel #.
__________________
Windows 10 I3 Dual Core 3.0 Server, SageTV9... OpenDCT with 2 HDHRPrimes and 4 HDHRconnects for a total of 14 Tuners.

Last edited by nyplayer; 07-01-2008 at 11:11 PM.
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Plugin: Sage Job Queue (SJQ) v3 Slugger SageTV Customizations 1355 07-25-2013 07:44 AM
Sage Job Queue (SJQ) new release notifications Slugger Customization Announcements 3 12-17-2009 09:59 AM
Sage Job Queue Completed tasks problem raffmanlt SageTV Customizations 2 08-18-2009 07:34 PM
Comskip Monitor VS Sage Job Queue SJQ personalt SageTV Customizations 6 03-02-2009 10:27 AM
Plugin: SJQ v1.1.0RC1 Available - Testers Needed Slugger SageTV Customizations 35 04-21-2008 08:12 AM


All times are GMT -6. The time now is 09:46 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.