Kodi Community Forum
error: script.favourites - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Skins Support (https://forum.kodi.tv/forumdisplay.php?fid=67)
+---- Forum: Transparency! (https://forum.kodi.tv/forumdisplay.php?fid=115)
+---- Thread: error: script.favourites (/showthread.php?tid=205274)



error: script.favourites - StefanK - 2014-09-27

I am unable to change the favourites in my submenus.
When I try I get the message error / script error / favourites script

The log file shows:
ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <class 'xml.parsers.expat.ExpatError'>
Error Contents: not well-formed (invalid token): line 60, column 201
Traceback (most recent call last):
File "C:\Users\XBMC\AppData\Roaming\XBMC\addons\script.favourites\default.py", line 169, in <module>
Main()
File "C:\Users\XBMC\AppData\Roaming\XBMC\addons\script.favourites\default.py", line 22, in __init__
found, favourites = self._read_file()
File "C:\Users\XBMC\AppData\Roaming\XBMC\addons\script.favourites\default.py", line 46, in _read_file
self.doc = parse( self.fav_file )
File "C:\Program Files (x86)\XBMC\system\python\Lib\xml\dom\minidom.py", line 1921, in parse
return expatbuilder.parse(file)
File "C:\Program Files (x86)\XBMC\system\python\Lib\xml\dom\expatbuilder.py", line 924, in parse
result = builder.parseFile(fp)
File "C:\Program Files (x86)\XBMC\system\python\Lib\xml\dom\expatbuilder.py", line 207, in parseFile
parser.Parse(buffer, 0)
ExpatError: not well-formed (invalid token): line 60, column 201
-->End of Python script error report<--

I did at one point delete the file favourites.xml, but I don't know if that has something to do with it...


RE: error: script.favourites - ronie - 2014-09-28

well, looks like the file is corrupt now.
you could try opening it with a text editor to check whats wrong.
'line 60, column 201' is where the error is, probably some odd character..


RE: error: script.favourites - StefanK - 2014-09-28

Thanks Ronie!
I deleted the line, which made the process work again.
Adding the favorite again though, only brings back the problem. Can you see what is wrong?
<favourite name="Artists" thumb="C:\Users\XBMC\AppData\Roaming\XBMC\addons\plugin.audio.googlemusic.exp\icon.png">ActivateWindow(10501,&quot;plugin://plugin.audio.googlemusic.exp/?path=filter&criteria=artist&quot;,return)</favourite>


RE: error: script.favourites - ronie - 2014-09-28

yeah, that line is indeed not valid xml.
it's probably a bug in xbmc i guess.

to work around it, manually edit that file and change the line to:
<favourite name="Artists" thumb="C:\Users\XBMC\AppData\Roaming\XBMC\addons\plugin.audio.googlemusic.exp\icon.png">ActivateWindow(10501,&quot;plugin://plugin.audio.googlemusic.exp/?path=filter&amp;criteria=artist&quot;,return)</favourite>


RE: error: script.favourites - StefanK - 2014-09-29

You're a genius - or at least very much more xml-savvy than I :-)
Thanks again


RE: error: script.favourites - ctawn - 2015-10-26

using the ampersand escapes saved my butt on this, too, just now.


RE: error: script.favourites - Atone69 - 2016-11-01

When i change to xonflunce I get the message error / script error / favourites script how can i fix an how to i post picture of error on fourms.. Im running kodi krypton beta on a Apple tv4 the error pervents me from adding a sub menu on home page


Favorites error