Kodi Community Forum
[OBSOLETE] Pandora Radio (Script) Music Addon - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Music Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=148)
+---- Thread: [OBSOLETE] Pandora Radio (Script) Music Addon (/showthread.php?tid=70471)



- pork - 2010-07-28

Well I was able to get it to install by commenting out "<provides>audio</provides>" but when I run it the script fails, new error:

http://pastebin.com/apvMPkd8


- Fiirikkusu - 2010-07-28

I feel bad for asking >_< ....where do your username and password go? I'm not sure what file or exactly what field to put them in.


- jurmb84 - 2010-07-31

@pork:

I will have to do some research on that... in reading your debug log, i think i have found the problem.
Code:
/home/brian/.xbmc/temp/strop.so: wrong ELF class: ELFCLASS32
/home/brian/.xbmc/temp/time.so: wrong ELF class: ELFCLASS32

according to http://forum.xbmc.org/archive/index.php/t-36744.html there is a known issue trying to run scripts on a 64-bit Linux OS. There is a suggestion on how to fix this, but i haven't tried as i force myself to run xbmc on 32-bit windows and 32-bit linux as there are less issues there...

@Fiirikkusu

if you run the script, it will fail for authentication... you can answer yes and it will take you to user/pass config screen... Use to be able to go to the context menu of the script and it would be there... but on the new framework i don't see it... Otherwise, you can manually enter it in the settings file... I use portable install so here is a reference:
Code:
C:\XBMC\portable_data\userdata\addon_data\script.xbmc.pandora\settings.xml
edit, or create, settings.xml in your above folder and enter the following:
Code:
<settings>
    <setting id="format" value="0" />
    <setting id="password" value="PASSWORD" />
    <setting id="username" value="USERNAME" />
</settings>
Obviously replacing USERNAME and PASSWORD with the appropriate logon info.


@both:

Please lemme know if any of this helps... Nod

Jurmb84


- badticket - 2010-07-31

Dear all,

a little surprising for me Pandora appears in the program section in windows XBMC.. not in the music section...
starting the script it shows "Failed to authenticate listener.". On PC with hotspot shield Pandora originally runs...

Does non american can't use the pandora script with xbmc ?

The settings shows my correct Pandora User + correct password...

Its the same message on Xbox1 & Windows XBMC ... "Failed to authenticate listener." May a geografical problem with my IP adress ?

Greetz


- jurmb84 - 2010-07-31

In doing some research, this is a script not a plugin. It seems, and correct me if I am wrong, that XBMC only allows plugins to be part of the Music/Video Addons section... Below is from wiki...

Code:
The library attribute provides the file of the python script that contains
the main entry point of your script. The <provides> element is a whitespace
separated list of [b]image, video, audio, executable[/b]. There is a schema
available here to check you have your XML correctly defined.

I didn't code this script, I just modified it to work with new addon framework. Would definately need the help of spbogie to get it transcribed to a plugin. However, that is why it is showing up in your programs section and not your plugins section. Based on what I now know, it is prefectly viable to remove the tag <provides>audio</provides> out of addon.xml as it does nothing for scripts... that is for use in plugins only. Didn't realize that as I was updating the code...

I use the skin Transparency at the moment and it allows modification of the menu to attach scripts in submenu... so i put pandora in the Music secion as it's own sub menu item. Check to see if you can do the same in your skin. Also, I have it hotkeyed to my remote using keymap.xml.

As far as geography is concerned, I don't know what Pandora's stance is on in/out of country. I live in the US and just checked again to make sure and the script is working fine from here. There is a good chance that you locale is stopping Pandora from authenticating. Do you proxy into the US to make it work from the web? If so, proxy is not yet available in the script. spbogie may have to do that part of it as i don't know where that would even be pulled from...
Will look into it when i get some time to do R&D... My biggest problem would be no way to test...

Hope this helps

Jurmb84


- Phantisy - 2010-07-31

Code:
/home/brian/.xbmc/temp/strop.so: wrong ELF class: ELFCLASS32
/home/brian/.xbmc/temp/time.so: wrong ELF class: ELFCLASS32

The way to fix that is to download the source and compile it and then move the python24.zip file over to your xbmc install. I can post my python24.zip I compiled on my ubuntu 10.04 x64 if you want and it should work fine. I have NO problems running this script on my 10.04 x64 box running the current svn 32381 as of today. If you want this file let me know.


- Fiirikkusu - 2010-07-31

@jurmb84

Mine doesn't like that >_< mines slightly different and if i were to see like "value" next to it it would have made me think to put the username/password. But ya I dunno squat about Linux. This is what my settings.xml looks like.

Code:
<settings>
    <setting id="username" type="text" label="Username (email)"/>
    <setting id="password" type="text" label="Password" option="hidden"/>
    <setting type="sep"/>
    <setting id="format" type="enum" label="Audio Format"
        values="aacplus|mp3|mp3-hifi" default="mp3"/>
</settings>



- tslayer - 2010-07-31

The settings.xml is actually supposed to be in:

~/.xbmc/userdata/addon_data/script.xbmc.pandora

Where ~ is your home directory.

Don't touch that settings.xml that you just showed. That isn't the one.

If you don't have one in ~/.xbmc/userdata/addon_data/script.xbmc.pandora, create it yourself as previously mentioned.


- Fiirikkusu - 2010-07-31

Thanks a lot tslayer ^_^ its working great now.

edit: I spoke too soon Sad ....the script runs fine but when its going to load the next song it stops the script. But it only seems to do it with Show Mix....so I'm assuming it has to do with that skin. It works fine with confluence. I also tried looking for those files AddonBrowser.xml, DialogAddonInfo.xml, DialogAddonSettings.xml and only found the last file inside the resolution folder.


- jurmb84 - 2010-08-01

@Fiirikkusu

Those 3 files should be in the tar.gz if you downloaded the source from my gitorious... inside script.xbmc.pandora there should be a folder called "PUT IN SKIN FOLDER"...

http://www.gitorious.org/~jurmb84/xbmc-pandora/jurmb84s-xbmc-pandora/trees/master/PUT%20IN%20SKIN%20FOLDER

Put those 3 files in the 1080i folder of showmix and that should allow the script to work correctly... i had to do the same... that is also why you couldn't bring up the settings screen when your authentication failed... requires those 3 files to operate correctly... Sucks that showmix is dead...

Transparency is freakin awesome though... gonna stick with that one for a while... works too good and looks too good to switch...

Hope this helps...

jurmb84


- Fiirikkusu - 2010-08-01

Ok well I basically used the packet that was linked to me and i used that but now it just completely fails :/ but one thing i noticed from the instructions given in this thread is that it has to be put into an addon folder. I dont have that. Im using XBMC Live and it only has a script folder and I believe thats part of the problem. I think this what I should be putting up...I pulled it from the xbmc.log file.

Code:
18:15:20 T:2912205680 M:2737983488  NOTICE: -->Python Interpreter Initialized<--
18:15:20 T:2912205680 M:2737983488  NOTICE: Traceback (most recent call last):
18:15:20 T:2912205680 M:2737983488  NOTICE:   File "/home/xbmc/.xbmc/scripts/script.xbmc.pandora/default.py", line 6, in ?
18:15:20 T:2912205680 M:2737983488  NOTICE: import xbmcaddon
18:15:20 T:2912205680 M:2737983488  NOTICE: ImportError
18:15:20 T:2912205680 M:2737983488  NOTICE: :
18:15:20 T:2912205680 M:2737983488  NOTICE: No module named xbmcaddon
18:15:20 T:2912205680 M:2737983488   ERROR: Scriptresult: Error



- jurmb84 - 2010-08-01

What SVN are you usingHuh This script is redone for the new addons... looks like you don't have the new addon framework if xbmcaddon is not found...


- Fiirikkusu - 2010-08-01

I think R26018


- jurmb84 - 2010-08-01

Damn... that is incredibly old... you must get the newer svn to get things working correctly... i am currently on SVN 32102... and i think there is newer yet at 323??.... They didn't switch to the new framework until after 28625....


- pork - 2010-08-02

Phantisy Wrote:
Code:
/home/brian/.xbmc/temp/strop.so: wrong ELF class: ELFCLASS32
/home/brian/.xbmc/temp/time.so: wrong ELF class: ELFCLASS32

The way to fix that is to download the source and compile it and then move the python24.zip file over to your xbmc install. I can post my python24.zip I compiled on my ubuntu 10.04 x64 if you want and it should work fine. I have NO problems running this script on my 10.04 x64 box running the current svn 32381 as of today. If you want this file let me know.

That would be great if you could post it for me. I'll give it a shot tonight. Thanks