SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV v7 Customizations
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV v7 Customizations This forums is for discussing and sharing user-created modifications for the SageTV version 7 application created by using the SageTV Studio or through the use of external plugins. Use this forum to discuss plugins for SageTV version 7 and newer.

Reply
 
Thread Tools Search this Thread Display Modes
  #21  
Old 01-15-2011, 03:22 PM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
Quote:
Originally Posted by Slack View Post
About adding shows that are not in TVDB such the local news etc...If the scraper finds no info it'll still add it to the library right? Just wont have any meta data?
Not yet...
It's currently designed to work with TV Series and Movies.
For other types of TV (no in the TVDB), I will probably (in a future release) end up manually adding to the XBMC library using Sage's Meta Data
This will require you to have a centralized MySQL database for XBMC.
Reply With Quote
  #22  
Old 01-15-2011, 03:32 PM
Slack's Avatar
Slack Slack is offline
Sage Aficionado
 
Join Date: Oct 2006
Posts: 256
OK Couple of questions. I realize I am not using the latest revs of the server or the Sagex api - but football has just begun recording and I am not going to muck with the server until tomorrow am if I have to upgrade to v7 or install the latest sagex api.

I'm a little unsure about the local path parameter in the config.xml
For my testing, your proggy is running on Win7 pro. And the Sage box is xp. I added one of the Sage recordings directories as "\\192.168.1.103\My Recordings" but did not supply a local equivalent because like I said I am not sure about that. On the Win7 box "\\192.168.1.103\My Recordings" is mapped as V:. Neither of these paths is "local to this program" as you state in the config.xml comments. Which I take to mean within the folder tree I placed your proggy. FYI: Your proggy is executed from D:\SageXBMC\SageXMBC\ at the moment.

Now, From the log for the first file...
Code:
2011 04:01:35 PM INFO      Retrieving XML from Sagex at URL: http://192.168.1.103:8888/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CAmericasFunniestHomeVideos-1702516-0.mpg
01/15/2011 04:01:35 PM ERROR     Cannot get valid XML from SageX API. Cannot continue. Cannot use local path (no local param supplied or local path is equal to default path). Please check the XML at http://192.168.1.103:8888/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CAmericasFunniestHomeVideos-1702516-0.mpg for integrity in these elements: <Airing>, <MediaFileID>, <ShowTitle>, <ShowEpisode>, <OriginalAiringDate>, <IsFileCurrentlyRecording>.
01/15/2011 04:01:35 PM INFO      Valid XML not found from sagex/api. Cannot continue.
It looks like your proggy needs to get an xml to parse.
In v7 is this file saved with the .mpg? In the recordings directory each recording has .mpg .txt. .edl. and .log all but the .mpg appear to be produced by commskip.
Or is it generated on the fly?
Or do I simply have my config.xml mucked up? (I supplied a single filter.)
Code:
  <add extension="mpg" redirect="true">House</add>
I know I am a non-compliant user what with v6 and all. But I am loathe to upgrade SageTV (cause it works so damn well right now) until I am sure I must, and that I can do it without breaking something as the whole family is pretty dependent on it.

Thanks for your patience.
Reply With Quote
  #23  
Old 01-15-2011, 03:33 PM
Slack's Avatar
Slack Slack is offline
Sage Aficionado
 
Join Date: Oct 2006
Posts: 256
Quote:
Originally Posted by bradvido View Post
This will require you to have a centralized MySQL database for XBMC.
I plan on that as I can imagine the benefits. But baby steps first.
Reply With Quote
  #24  
Old 01-15-2011, 06:08 PM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
The local equiv paths are optional. Think of them as just an alternate path to try if the normal path won't work. Also, for CC Extraction, local paths provide improved compatibility (in my testing anyway).

It looks like you are using UNC paths, and that is good for a distributed system. So you should be fine there.

The program relies on the sagex web service for getting meta-data about the recordings. Without it up and running, you aren't going to get anywhere.
Reply With Quote
  #25  
Old 01-16-2011, 08:56 AM
Slack's Avatar
Slack Slack is offline
Sage Aficionado
 
Join Date: Oct 2006
Posts: 256
Quote:
Originally Posted by bradvido View Post
The program relies on the sagex web service for getting meta-data about the recordings. Without it up and running, you aren't going to get anywhere.
Understood. And it is running....



First I will update it to latest rev.
If that gets me nowhere I will upgrade SaveTV to v7.
Reply With Quote
  #26  
Old 01-16-2011, 01:03 PM
Slack's Avatar
Slack Slack is offline
Sage Aficionado
 
Join Date: Oct 2006
Posts: 256
Update:
Installed Sage v7.
Updated firmware on HD-200.
Installed Plugin via GUI on HD200 - "sagex-services".
This installed 'Jetty' webserver and...
sagex-services (which failed) according to the gui on the HD200
So I Re-installed sagex-services via the gui...
success at least per the gui
I decided to move my sabnzb server from port 8080 to 8088 (so jetty would work on port 8080)
Launched browser and pointed to jetty...long list of errors.
Updated java on server box - rebooted.
Jetty now happy - lists one app "sagex"

Changed url for sagex in SageXBMC config.xml to use port 8080 (was 8888)
Tried SageXBMC again..."
Code:
01/16/2011 01:33:22 PM INFO      ######################################START LOADING CONFIG######################################
01/16/2011 01:33:22 PM INFO      Getting config from XML file: D:\SageXBMC\SageXBMC\config.xml
01/16/2011 01:33:22 PM INFO      ######################################START CHECKING CURRENT ENCODES######################################
01/16/2011 01:33:22 PM INFO      Checking for external encodings that might have finished
01/16/2011 01:33:22 PM INFO      0 current encodings found, skipping
01/16/2011 01:33:22 PM INFO      ######################################START CHECKING XBMC UPDATES######################################
01/16/2011 01:33:22 PM INFO      Checking if XBMC needs to have its sources updated for any video files by checking entries in D:\SageXBMC\SageXBMC\res\xbmcFileSources.txt
01/16/2011 01:33:22 PM INFO      Will check the sources for 0 videos in XBMC
01/16/2011 01:33:22 PM INFO      Done updating XBMC sources. (checked 0 sources, updated 0, removed: 0)
01/16/2011 01:33:22 PM INFO      ######################################START PROCESSING SHOWFILTER MATCHESS######################################
01/16/2011 01:33:23 PM INFO      Retrieving XML from Sagex at URL: http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CAmericasFunniestHomeVideos-1702516-0.mpg
01/16/2011 01:33:23 PM ERROR     Cannot get valid XML from SageX API. Cannot continue. Cannot use local path (no local param supplied or local path is equal to default path). Please check the XML at http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CAmericasFunniestHomeVideos-1702516-0.mpg for integrity in these elements: <Airing>, <MediaFileID>, <ShowTitle>, <ShowEpisode>, <OriginalAiringDate>, <IsFileCurrentlyRecording>.
01/16/2011 01:33:23 PM INFO      Valid XML not found from sagex/api. Cannot continue.
So I am not sure what the issue is.
SageTV server (running as service) is @ v7.
Jetty web server functions @ "http://192.168.1.103:8080/apps/"
Dunno if this is pertinent but when I click on the sagex listing in jetty - I get a 404 and "No Sage Handler Specified."
Neilm's webserver functions @ "http://192.168.1.103:8888/sage/home"
Sagex is accessible @ "http://192.168.1.103:8888/sagex/api" (version 7.0.23.3)
sagex also responds @ "http://192.168.1.103:8080/sagex/api" (version 7.0.23.3)

I have tried SageXMBC with both URLs - both error out.
Reply With Quote
  #27  
Old 01-16-2011, 02:14 PM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
This error usually means that XML was retrieved successfully, but it didn't have the expected content.
Code:
01/16/2011 01:33:23 PM ERROR     Cannot get valid XML from SageX API. Cannot continue. Cannot use local path (no local param supplied or local path is equal to default path). Please check the XML at http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CAmericasFunniestHomeVideos-1702516-0.mpg for integrity in these elements: <Airing>, <MediaFileID>, <ShowTitle>, <ShowEpisode>, <OriginalAiringDate>, <IsFileCurrentlyRecording>.
What do you see when you browse to this URL in your web browser?
Code:
http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CAmericasFunniestHomeVideos-1702516-0.mpg
If it's an empty <Result /> element, that means that your Path for the recording is not the same as Sage's path for the recording.
See this post for details about that: http://forum.xbmc.org/showpost.php?p...9&postcount=17

Last edited by bradvido; 01-16-2011 at 02:32 PM.
Reply With Quote
  #28  
Old 01-16-2011, 03:03 PM
Slack's Avatar
Slack Slack is offline
Sage Aficionado
 
Join Date: Oct 2006
Posts: 256
Per the topic you linked...
sagex considers the path to be "D:\My Recordings"
Quote:
<SegmentFiles size="1"><File>D:\My Recordings\Soundstage-JohnFogerty-1381053-0.mpg</File>
And it returns xml if I feed it a show name using that path...
Code:
<MediaFile><MediaFileFormatDescription>MPEG2-PS[MPEG2-Video 16:9 1080i@29.97fps, Dolby Digital/384Kbps@48kHz 5.1, Dolby Digital/192Kbps@48kHz Stereo]</MediaFileFormatDescription>
From your config.xml
Quote:
local_equiv - optional, If you are using a UNC path, but the directory is local to this program,
it is recommended to add a local_equiv attribute specifying the
local directory that is equivalent to the UNC path.
Is the local equivalent path in reference to the Sage server box?
Because I considered it to be in reference to the Win7 box I am running your application on.

The SageTV box (win XP) has no drive letter mapping of the UNC \\192.168.1.103\My Recordings
Reply With Quote
  #29  
Old 01-16-2011, 03:22 PM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
Quote:
Originally Posted by Slack View Post
Per the topic you linked...
sagex considers the path to be "D:\My Recordings"

Is the local equivalent path in reference to the Sage server box?
Because I considered it to be in reference to the Win7 box I am running your application on.

The SageTV box (win XP) has no drive letter mapping of the UNC \\192.168.1.103\My Recordings
#1 if you are planning on having a distributed system, I would change Sage's recording paths to use a UNC path.... but that is not something you need to do to get this program working.
#2 I'm working off my memory as I don't have the code in front of me, but I believe the local_equiv for your recording directories does not need to exist on the box where this program runs. It is in reference to the Sage server. So you can add a local_equiv attribute like so:
Code:
<dir local_equiv="D:\My Recordings">\\192.168.1.103\My Recordings</dir>
And the sagex XML query will work.

UPDATE: Just looked at the code. As long as you aren't doing CCExtraction, the local_equiv does not need to exist on the computer where the program is running. It only needs to exist on the SageTV server.

Last edited by bradvido; 01-16-2011 at 03:29 PM.
Reply With Quote
  #30  
Old 01-16-2011, 03:53 PM
Slack's Avatar
Slack Slack is offline
Sage Aficionado
 
Join Date: Oct 2006
Posts: 256
I am not using CC extract. And agree that I should be able to make this work without having sage record to a UNC path.
After looking at the error logs - I believe local equivalent is in reference to SageTV box.
And, also, from what I can tell if I feed the sagex the url manually via a browser on my Win7 box it returns the xml for the show.

However, according to the error log: it indicates that the same url fails when the semicolon and the space characters are replaced by their symbolic equivalents.
In a nutshell...
"D:\My Recordings" in the url works when manually entered.
"D%3AMy+Recordings" fails (this is what is passed to sagex by the application according to the error log).

Works (I see a page of XML)
Code:
http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=D:\My Recordings\House-APoxonOurHouse-1842215-0.mpg
Fails (see a null result)
Code:
http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=D%3AMy+Recordings\House-APoxonOurHouse-1842215-0.mpg
Header and first error from error log.

Code:
01/16/2011 04:30:26 PM INFO      ######################################START LOADING CONFIG######################################
01/16/2011 04:30:26 PM INFO      Getting config from XML file: D:\SageXBMC\SageXBMC\config.xml
01/16/2011 04:30:26 PM INFO      ######################################START CHECKING CURRENT ENCODES######################################
01/16/2011 04:30:26 PM INFO      Checking for external encodings that might have finished
01/16/2011 04:30:26 PM INFO      0 current encodings found, skipping
01/16/2011 04:30:26 PM INFO      ######################################START CHECKING XBMC UPDATES######################################
01/16/2011 04:30:26 PM INFO      Checking if XBMC needs to have its sources updated for any video files by checking entries in D:\SageXBMC\SageXBMC\res\xbmcFileSources.txt
01/16/2011 04:30:26 PM INFO      Will check the sources for 0 videos in XBMC
01/16/2011 04:30:26 PM INFO      Done updating XBMC sources. (checked 0 sources, updated 0, removed: 0)
01/16/2011 04:30:26 PM INFO      ######################################START PROCESSING SHOWFILTER MATCHESS######################################
01/16/2011 04:30:27 PM INFO      Found matching recording: \\192.168.1.103\My Recordings\House-APoxonOurHouse-1842215-0.mpg
01/16/2011 04:30:27 PM INFO      Checking if \\192.168.1.103\My Recordings\House-APoxonOurHouse-1842215-0.mpg can be processed right now.
01/16/2011 04:30:27 PM INFO      Retrieving XML from Sagex at URL: http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CHouse-APoxonOurHouse-1842215-0.mpg
01/16/2011 04:30:27 PM INFO      Could not get valid data from standard file location, trying local URL: http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=D%3AMy+Recordings%5CHouse-APoxonOurHouse-1842215-0.mpg
01/16/2011 04:30:27 PM ERROR     Cannot get valid XML from SageX API even after using local path at http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=D%3AMy+Recordings%5CHouse-APoxonOurHouse-1842215-0.mpg. Cannot continue. Please check the XML at http://192.168.1.103:8080/sagex/api?c=GetMediaFileForFilePath&1=%5C%5C192.168.1.103%5CMy+Recordings%5CHouse-APoxonOurHouse-1842215-0.mpg for integrity in these elements: <Airing>, <MediaFileID>, <ShowTitle>, <ShowEpisode>, <OriginalAiringDate>, <IsFileCurrentlyRecording>.
java.lang.Exception: Neither normal nor local path returned valid XML
	at sage.SageToXBMC.getRootElementFromSageX(SageToXBMC.java:1624)
	at sage.SageToXBMC.processVideo(SageToXBMC.java:1667)
	at sage.SageToXBMC.scanForMatchingFiles(SageToXBMC.java:1090)
	at sage.SageToXBMC.<init>(SageToXBMC.java:860)
	at sage.SageToXBMC.main(SageToXBMC.java:126)
Reply With Quote
  #31  
Old 01-16-2011, 04:22 PM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
Hmm... It is using a standard URL Encoder, and it's generally considered good practice to encode URLs. I'm surprised that it doesn't work with the encoded URL. It's an easy code change for me to try the non-encoded URL as well. I'll do that and give you an update.

Looking closer at the encoded URL, it looks like it's encoded incorrectly.
D:\ should be
D%3A%5C
But it's turning into just D%3A.
Do me a favor and check and make sure you local_equiv attribute has the "\" in it, and it's not D:My Recordings

Let me see whats going on. Looks like you might have found a bug.

Last edited by bradvido; 01-16-2011 at 07:27 PM.
Reply With Quote
  #32  
Old 01-17-2011, 06:44 AM
Slack's Avatar
Slack Slack is offline
Sage Aficionado
 
Join Date: Oct 2006
Posts: 256
Quote:
Originally Posted by bradvido View Post
Do me a favor and check and make sure you local_equiv attribute has the "\" in it, and it's not D:My Recordings

.
Looks like I was getting sloppy (must have edited that line 5 or 6 times).
Code:
	<SageRecordingDirs>
		<!--<dir>D:\My Recordings</dir> Example Only, please modify -->
		<dir local_equiv="D:My Recordings">\\192.168.1.103\My Recordings</dir><!--Example Only, please modify -->		
	</SageRecordingDirs>
I fixed it and now I see 4 episodes of 'House' in the drop box location I specified.

Thanks.
When I get home I'll add the dropbox as a source. And play around a bit.


Thanks again, for the patience.
Reply With Quote
  #33  
Old 01-25-2011, 03:39 PM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
V 1.3 release with many new features.
All the details are here: http://forum.xbmc.org/showthread.php?p=661756

Most exciting feature: now every SageTV recording can be added to your XBMC library (even if it's episode and season number are unknown).

Such as News programs or NFL games:

The "Aired" and "Genre" are also added, this screenshot is a little out of date

Last edited by bradvido; 01-25-2011 at 03:44 PM.
Reply With Quote
  #34  
Old 01-26-2011, 08:35 AM
dgeezer dgeezer is offline
Sage Aficionado
 
Join Date: Oct 2007
Location: Greensboro, NC
Posts: 293
When I run the run-x64.cmd I get this error:

D:\SAGE-XBMC v1.3\dist>"C:\Program Files (x86)\Java\jre6\bin\java.exe" -jar "Sag
eXBMC.jar"
Failed to check for an already running instance of this script, this can cause u
ndesired behavior: java.io.FileNotFoundException: D:\SAGE-XBMC%20v1.3\res\single
Instance.txt (The system cannot find the path specified)
Unknown eror: java.lang.NullPointerException
java.lang.NullPointerException
at utilities.Config.log(Config.java:905)
at utilities.Config.<init>(Config.java:155)
at sage.SageToXBMC.<init>(SageToXBMC.java:202)
at sage.SageToXBMC.main(SageToXBMC.java:50)
Failed to check for an already running instance of this script, this can cause u
ndesired behavior: java.io.FileNotFoundException: D:\SAGE-XBMC%20v1.3\res\single
Instance.txt (The system cannot find the path specified)

D:\SAGE-XBMC v1.3\dist>pause
Press any key to continue . . .

It appears that my path to Java is correct but that somehow the program can't find the singleinstance.txt file. I don't see any way to change this path. Am I missing something obvious?
Reply With Quote
  #35  
Old 01-26-2011, 09:03 AM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
Quote:
Originally Posted by dgeezer View Post
When I run the run-x64.cmd I get this error:

D:\SAGE-XBMC v1.3\dist>"C:\Program Files (x86)\Java\jre6\bin\java.exe" -jar "Sag
eXBMC.jar"
Failed to check for an already running instance of this script, this can cause u
ndesired behavior: java.io.FileNotFoundException: D:\SAGE-XBMC%20v1.3\res\single
Instance.txt (The system cannot find the path specified)
Unknown eror: java.lang.NullPointerException
java.lang.NullPointerException
at utilities.Config.log(Config.java:905)
at utilities.Config.<init>(Config.java:155)
at sage.SageToXBMC.<init>(SageToXBMC.java:202)
at sage.SageToXBMC.main(SageToXBMC.java:50)
Failed to check for an already running instance of this script, this can cause u
ndesired behavior: java.io.FileNotFoundException: D:\SAGE-XBMC%20v1.3\res\single
Instance.txt (The system cannot find the path specified)

D:\SAGE-XBMC v1.3\dist>pause
Press any key to continue . . .

It appears that my path to Java is correct but that somehow the program can't find the singleinstance.txt file. I don't see any way to change this path. Am I missing something obvious?
signleInstance.txt should have come with the installation.
It should be at INSTALL_DIR\res\singleInstance.txt
Do you see it there? The program this this is:
Code:
D:\SAGE-XBMC v1.3\res\singleInstance.txt

EDIT: Looks like you've found a bug.
Take the space out of your folder name, and it will work;

Use D:\SAGE-XBMC-v1.3 instead of D:\SAGE-XBMC v1.3\

Last edited by bradvido; 01-26-2011 at 09:11 AM.
Reply With Quote
  #36  
Old 01-26-2011, 03:25 PM
dgeezer dgeezer is offline
Sage Aficionado
 
Join Date: Oct 2007
Location: Greensboro, NC
Posts: 293
Thanks
I've got the script running now.
Reply With Quote
  #37  
Old 02-15-2011, 02:31 PM
bradvido's Avatar
bradvido bradvido is offline
Sage User
 
Join Date: Nov 2010
Location: MN
Posts: 68
Just released v1.4 with quite a few feature enhancements and bug fixes.
If you're interested:
http://forum.xbmc.org/showthread.php?p=661756
http://forum.xbmc.org/showpost.php?p...3&postcount=96
Reply With Quote
Reply

Tags
boxee, integration, xbmc


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

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
Will XBMC interfere with SageTV? tonysathre Sage My Movies 1 09-08-2010 03:39 PM
XBMC SageTv Plugin mikwilli SageTV Customizations 95 04-30-2010 12:50 PM
XBMC plugin for SageTV jhh SageTV Customizations 45 04-19-2009 01:16 PM
SageTV vs. XBMC MediaStream UI? SørenBM SageMC Custom Interface 2 03-07-2009 02:29 PM
XBMC Script for SageTV Released 3/1/2006 Coolwave SageTV Customizations 361 03-04-2009 03:15 PM


All times are GMT -6. The time now is 08:48 AM.


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