SageTV Community  

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

Notices

Phoenix This forum is for discussing the user-created Phoenix custom interface for SageTV.

Reply
 
Thread Tools Search this Thread Display Modes
  #81  
Old 02-02-2014, 05:23 AM
davidk21770 davidk21770 is offline
Sage Expert
 
Join Date: Mar 2006
Location: Maryland
Posts: 514
Quote:
Originally Posted by skiingwiz View Post
I just tried this for the first time tonight, running 1.0.3. I'm having the same view problems (no items) with both builtin and my custom phoenix views. Below is what I think are the relevant log entries. I've bolded the part I think is the problem. I have also verified that the URL in the log returns a response that looks valid when using a browswer. Hopefully this helps narrow it down.

Edit: Maybe the sagex apis aren't returning utf-8 encoded text (rather ISO-Latin1 maybe), but plex is trying to read it that way??
When I run the page that's in your "Quote" (http://127.0.0.1:8080/sagex/phoenix?...teView&end=100), it downloads fine into firefox.
Type: text/plain
Render Mode: Quirks mode
Encoding: windows-1252
__________________
HDHomeRun x2
Cable Box via Hauppauge HD PVR and USB-UIRT
2 SageTV's HD300

Intel Core 2 Quad Q9650 @4025 MHz, 8G G.Skill Performance
DFI Lanparty DK X48-T2RS Plus; SilverStone Decathlon DA1000 (died - back to an ancient enermax)
eVGA 7900 GT KO RoHS -- Zalman VP900CU Cooling
Synology NAS 22TB
Reply With Quote
  #82  
Old 02-02-2014, 05:44 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Well, it does appear that I wasn't handling the encoding correctly

Instead of doing a full release, just to test this, I created JUST the jar file.

https://github.com/stuckless/sagetv-....5.11-beta-jar

If you shutdown sagetv, download this, and replace the jar in your SAGE_HOME/JARs/ with this one, it should encode correctly. If this works for people, then I'll go through the effort of actually pushing out a new phoenix release.

You can test this in your browser by issuing the URL..
http://localhost:8080/sagex/phoenix?....util.Echo&1=©

If you get the reply back with the copyright symbol (instead of ?) then it's working. (In Google Chrome I use the PostMan plugin for testing REST apis -- it does a nice job of allowing you to inspect the formatted reply, headers, etc)
Reply With Quote
  #83  
Old 02-02-2014, 05:48 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by davidk21770 View Post
When I run the page that's in your "Quote" (http://127.0.0.1:8080/sagex/phoenix?...teView&end=100), it downloads fine into firefox.
Type: text/plain
Render Mode: Quirks mode
Encoding: windows-1252
It just means that FF does a better job at handling invalid encodings... And based on your output, it does confirm that I'm encoding it incorrectly, since the encoding should say, "UTF-8". I've updated a new phoenix.jar (see my prev post) for testing.
Reply With Quote
  #84  
Old 02-02-2014, 06:17 AM
davidk21770 davidk21770 is offline
Sage Expert
 
Join Date: Mar 2006
Location: Maryland
Posts: 514
Quote:
Originally Posted by stuckless View Post
It just means that FF does a better job at handling invalid encodings... And based on your output, it does confirm that I'm encoding it incorrectly, since the encoding should say, "UTF-8". I've updated a new phoenix.jar (see my prev post) for testing.
YES!
I haven't run it through all of its paces, but I checked several of the links and all had videos and I test played one just to make sure.
Thanks!

Edit: however, your link returns a "?" to FF. But it shows utf-8 encoding.
__________________
HDHomeRun x2
Cable Box via Hauppauge HD PVR and USB-UIRT
2 SageTV's HD300

Intel Core 2 Quad Q9650 @4025 MHz, 8G G.Skill Performance
DFI Lanparty DK X48-T2RS Plus; SilverStone Decathlon DA1000 (died - back to an ancient enermax)
eVGA 7900 GT KO RoHS -- Zalman VP900CU Cooling
Synology NAS 22TB

Last edited by davidk21770; 02-02-2014 at 06:52 AM.
Reply With Quote
  #85  
Old 02-02-2014, 07:50 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by davidk21770 View Post
YES!
I haven't run it through all of its paces, but I checked several of the links and all had videos and I test played one just to make sure.
Thanks!

Edit: however, your link returns a "?" to FF. But it shows utf-8 encoding.
That is great news
Reply With Quote
  #86  
Old 02-02-2014, 07:54 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
@brewston I realize this is same bug you posted a week ago... sorry it's taken this long for me to really look into it
Reply With Quote
  #87  
Old 02-02-2014, 07:59 AM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 4,997
It works ... Maybe you can add a View that is normal Grouped alphabetically Grouped sorted by Season then sorted by episodes. I thought all TVShows would do this... Great Job thank you.
__________________
Channels DVR UBUNTU Server 2 Primes 3 Connects TVE SageTV Docker with input from Channels DVR XMLTV and M3U VIA Opendct.
Reply With Quote
  #88  
Old 02-02-2014, 09:52 AM
jorton jorton is offline
Sage Icon
 
Join Date: Jul 2005
Location: Canada
Posts: 1,273
New jar also worked for me, thanks Stuckless
Reply With Quote
  #89  
Old 02-02-2014, 10:57 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by nyplayer View Post
It works ... Maybe you can add a View that is normal Grouped alphabetically Grouped sorted by Season then sorted by episodes. I thought all TVShows would do this... Great Job thank you.
There's a section on creating your own custom main menu...

https://github.com/stuckless/sagetv-...-the-Main-Menu

The view you are after is called, phoenix.view.default.allTV, or phoenix.view.default.allTVseasons.

I've actually updated the main plugin file to use phoenix.view.default.allTV in future releases... (although you can download it directly and replace the init.py with this one...
https://github.com/stuckless/sagetv-...de/__init__.py in case you don't want to create your menu)

Also, I use an 'Unwatched TV' which is not part of core phoenix (but should be)... You can find it here...

https://gist.github.com/stuckless/8639637
Reply With Quote
  #90  
Old 02-02-2014, 11:16 AM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 4,997
I replaced the init PY but the channel no longer shows up in plex.

Code:
 File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\core.py", line 550, in load_code
    self.init_code = self.loader.load(self.init_path, elevated, use_xpython = Framework.constants.flags.use_xpython in self.sandbox.flags)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\code\loader.py", line 47, in load
    code = self.compile(str(source), str(uni(filename)), elevated)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\code\loader.py", line 52, in compile
    return RestrictedPython.compile_restricted(source, name, 'exec', elevated=elevated)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 115, in compile_restricted
    gen.compile()
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 68, in compile
    tree = self._get_tree()
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 59, in _get_tree
    tree = self.parse()
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 56, in parse
    return niceParse(self.source, self.filename, self.mode)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 38, in niceParse
    compile(source, filename, mode)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\SageTVPhoenix.bundle\Contents\Code\__init__.py", line 6
    <!DOCTYPE html>
    ^
SyntaxError: invalid syntax
__________________
Channels DVR UBUNTU Server 2 Primes 3 Connects TVE SageTV Docker with input from Channels DVR XMLTV and M3U VIA Opendct.

Last edited by nyplayer; 02-02-2014 at 11:30 AM.
Reply With Quote
  #91  
Old 02-02-2014, 11:32 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Use the "RAW" version of that file (now the formatted html)

https://raw.github.com/stuckless/sag...de/__init__.py


Quote:
Originally Posted by nyplayer View Post
I replaced the init PY but the channel no longer shows up in plex.

Code:
 File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\core.py", line 550, in load_code
    self.init_code = self.loader.load(self.init_path, elevated, use_xpython = Framework.constants.flags.use_xpython in self.sandbox.flags)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\code\loader.py", line 47, in load
    code = self.compile(str(source), str(uni(filename)), elevated)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\code\loader.py", line 52, in compile
    return RestrictedPython.compile_restricted(source, name, 'exec', elevated=elevated)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 115, in compile_restricted
    gen.compile()
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 68, in compile
    tree = self._get_tree()
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 59, in _get_tree
    tree = self.parse()
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 56, in parse
    return niceParse(self.source, self.filename, self.mode)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\RestrictedPython\RCompile.py", line 38, in niceParse
    compile(source, filename, mode)
  File "C:\Users\SAGETVUSER\AppData\Local\Plex Media Server\Plug-ins\SageTVPhoenix.bundle\Contents\Code\__init__.py", line 6
    <!DOCTYPE html>
    ^
SyntaxError: invalid syntax
Reply With Quote
  #92  
Old 02-02-2014, 11:40 AM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 4,997
Created a view just had to change the sort to title


PS I am not sure if it is supposed to work on Plex Home Theatre but the shows will not play. Views work fine but will not play.
They do play great in Roku.
__________________
Channels DVR UBUNTU Server 2 Primes 3 Connects TVE SageTV Docker with input from Channels DVR XMLTV and M3U VIA Opendct.

Last edited by nyplayer; 02-02-2014 at 12:38 PM.
Reply With Quote
  #93  
Old 02-02-2014, 12:32 PM
thatdude90210 thatdude90210 is offline
Sage Aficionado
 
Join Date: Feb 2004
Posts: 385
Awesome works stuckless, everything works as expected.

Only item that errors out is the "about" button.
Reply With Quote
  #94  
Old 02-02-2014, 01:39 PM
brewston brewston is offline
Sage Expert
 
Join Date: Apr 2006
Location: Surrey
Posts: 719
Quote:
Originally Posted by stuckless View Post
@brewston I realize this is same bug you posted a week ago... sorry it's taken this long for me to really look into it
No worries. Thanks for looking at it.

I dropped in the new phoenix.jar (With Sage service stopped) but it's still not working

When I access your test URL (to return ©)


I get :

HTTP ERROR 404

Problem accessing /sagex/phoenix. Reason:

ERROR: java.lang.Exception: Unknown API Method Echo for API phoenix.util
at sagex.phoenix.remote.RemoteAPI.getMethod(RemoteAPI.java:248)
at sagex.phoenix.remote.RemoteAPI.invokeAPI(RemoteAPI.java:190)
at sagex.phoenix.remote.RemoteAPI.callAPI(RemoteAPI.java:74)
at sagex.phoenix.remote.PhoenixAPIHander.handleRequest(PhoenixAPIHander.java:127)
at sagex.remote.SagexServlet.doPost(SagexServlet.java:60)
at sagex.remote.SagexServlet.doGet(SagexServlet.java:38)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:389)
at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.handler.rewrite.RewriteHandler.handle(RewriteHandler.java:230)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:534)
at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:864)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409)
at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:520)


BMT front page reports Phoenix version 2.5.11

Did I mess up the install ? I'll try again later when my downtime window is open
__________________
Tecra M5, 2 x HD200, 2 x HD300
2 x PCTV 290e
Win 7, Sage 7.1.9, Phoenix 2 STV
Stephane's XMLTV Importer, Digiguide,
Reply With Quote
  #95  
Old 02-02-2014, 02:50 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by brewston View Post
No worries. Thanks for looking at it.

I dropped in the new phoenix.jar (With Sage service stopped) but it's still not working

When I access your test URL (to return ©)


I get :

HTTP ERROR 404

Problem accessing /sagex/phoenix. Reason:

ERROR: java.lang.Exception: Unknown API Method Echo for API phoenix.util


BMT front page reports Phoenix version 2.5.11

Did I mess up the install ? I'll try again later when my downtime window is open
Well, it's basically saying the 'Echo' api doesn't exist, and it's a new API that I added in this release, just to test if the encoding was working. The api itself is not important, but if it's complaining that it's not there, then it's likely that the jar is not installed correctly.
Reply With Quote
  #96  
Old 02-02-2014, 02:51 PM
skiingwiz skiingwiz is offline
Sage Aficionado
 
Join Date: Jan 2005
Posts: 366
Quote:
Originally Posted by stuckless View Post
If this works for people, then I'll go through the effort of actually pushing out a new phoenix release.
Just one more confirmation. This new JAR fixed the problem for me.

Thanks stuckless!
Reply With Quote
  #97  
Old 02-02-2014, 02:52 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by nyplayer View Post
PS I am not sure if it is supposed to work on Plex Home Theatre but the shows will not play. Views work fine but will not play.
They do play great in Roku.
To be honest, I haven't tested in PHT... I don't actually PHT installed. If I get a chance I'll see what might be going on there.
Reply With Quote
  #98  
Old 02-02-2014, 04:19 PM
brewston brewston is offline
Sage Expert
 
Join Date: Apr 2006
Location: Surrey
Posts: 719
Quote:
Originally Posted by stuckless View Post
Well, it's basically saying the 'Echo' api doesn't exist, and it's a new API that I added in this release, just to test if the encoding was working. The api itself is not important, but if it's complaining that it's not there, then it's likely that the jar is not installed correctly.

All working now. There was some kind of weirdness going on with the permissions on the .jar file, so I just made them look the perm on the original phoenix.jar


Thanks !!
__________________
Tecra M5, 2 x HD200, 2 x HD300
2 x PCTV 290e
Win 7, Sage 7.1.9, Phoenix 2 STV
Stephane's XMLTV Importer, Digiguide,
Reply With Quote
  #99  
Old 02-03-2014, 12:26 PM
nyplayer nyplayer is offline
SageTVaholic
 
Join Date: Sep 2005
Posts: 4,997
when I bring up all movies etc... How do I get to the next page on the browser?
__________________
Channels DVR UBUNTU Server 2 Primes 3 Connects TVE SageTV Docker with input from Channels DVR XMLTV and M3U VIA Opendct.
Reply With Quote
  #100  
Old 02-03-2014, 12:47 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,713
Quote:
Originally Posted by nyplayer View Post
when I bring up all movies etc... How do I get to the next page on the browser?
I purposely limit (via the menu file) the number of items that are loaded... I do this, because loading 1000s of items into a a device like the roku will kill it

There is no paging, since there isn't an easy way to do paging in plex... it is possible... just not easy

That's why I create views like "unwatched tv" and "unwatched movies", etc, since those are smaller views.

You can also use the "Search" to search the sagetv media files as well.

Feel free to add a bug/enh request on the issue site... If I get time, I'll add paging.
Reply With Quote
Reply


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
Plex Scanner and BMT Agent for SageTV PiX64 SageTV v7 Customizations 1412 11-11-2022 12:35 AM
Roku+Plex = Leaving SageTV? Anyone regret it? IVB The SageTV Community 60 08-29-2013 07:57 PM
Should I buy SageTV Media Center or Media Server? (re: headless server box) sofakng SageTV Software 5 03-12-2011 03:56 PM
Possible to get SageTV to handle my library more like Plex? DAMAC SageTV Mac Edition 0 06-10-2009 10:33 AM
How Does SageTV Media Server for Windows Home Server work? PhillTheChill SageTV Software 7 11-16-2007 01:46 PM


All times are GMT -6. The time now is 11:24 AM.


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