2012-08-31, 12:17
Where can this addon be downloaded? I cannot locate it in the xbmc.org repo using the instructions from http://wiki.xbmc.org/index.php?title=How...ptional.29
svn co http://xbmc-pydev-predefcom.googlecode.com/svn/trunk/script.pypredefcom/ script.pypredefcom
ERROR: Traceback (most recent call last):
File "C:\Program Files\XBMC\addons\script.pypredefcom\addon.py", line 56, in <module>
Addon = xbmcaddon.Addon( id=os.path.basename( os.getcwd() ) )
Exception: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
Addon = xbmcaddon.Addon( id='script.pypredefcom' )
(2012-09-10, 13:22)jfcarroll Wrote: ... it will work. I'm moving the project to GitHub and rereleasing it. Sorry for the trouble.Sure, I did find this by myself... Thanks a lot, it works fine now!
INFO: -->Python script returned the following error<--
ERROR: Error Type: <type 'exceptions.UnicodeDecodeError'>
ERROR: Error Contents: 'ascii' codec can't decode byte 0xd0 in position 13: ordinal not in range(128)
ERROR: Traceback (most recent call last):
File "/home/mefody/.xbmc/addons/script.pypredefcom/addon.py", line 84, in <module>
pDialog.update(count * 25, Addon.getLocalizedString(30711 ) % (module + ".pypredef", ), Addon.getLocalizedString(30712) % (predefcompath, ) )
UnicodeDecodeError: 'ascii' codec can't decode byte 0xd0 in position 13: ordinal not in range(128)
INFO: -->End of Python script error report<--
(2012-09-10, 14:29)Mefody Wrote:Well known problem(2012-09-10, 13:22)jfcarroll Wrote: ... it will work. I'm moving the project to GitHub and rereleasing it. Sorry for the trouble.Sure, I did find this by myself... Thanks a lot, it works fine now!
Only as remark...
Addon works perfect if the full path to goal folder has ASCII English. For localized names it crashes:
Code:INFO: -->Python script returned the following error<--
ERROR: Error Type: <type 'exceptions.UnicodeDecodeError'>
ERROR: Error Contents: 'ascii' codec can't decode byte 0xd0 in position 13: ordinal not in range(128)
ERROR: Traceback (most recent call last):
File "/home/mefody/.xbmc/addons/script.pypredefcom/addon.py", line 84, in <module>
pDialog.update(count * 25, Addon.getLocalizedString(30711 ) % (module + ".pypredef", ), Addon.getLocalizedString(30712) % (predefcompath, ) )
UnicodeDecodeError: 'ascii' codec can't decode byte 0xd0 in position 13: ordinal not in range(128)
INFO: -->End of Python script error report<--
.decode('utf-8')
(2012-09-10, 14:52)Martijn Wrote: Well known problemIt's not a problem for me - I use English path/names from times of old good MSDOS & Turbo C
try adding:
PHP Code:.decode('utf-8')
WARNING: XFILE::CFileFactory::CreateLoader - Unsupported protocol(addons) in addons://more/executable.tbn
16:02:22 T:2592 NOTICE: -->Python Interpreter Initialized<--
16:02:22 T:2592 ERROR: Error Type: <type 'exceptions.Exception'>
16:02:22 T:2592 ERROR: Error Contents: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
16:02:22 T:2592 ERROR: Traceback (most recent call last):
File "C:\Users\traesprit\AppData\Roaming\XBMC\addons\script.pypredefcom\addon.py", line 56, in <module>
Addon = xbmcaddon.Addon( id=os.path.basename( os.getcwd() ) )
Exception: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
16:02:51 T:4472 WARNING: XFILE::CFileFactory::CreateLoader - Unsupported protocol(addons) in addons://more/executable.tbn
16:02:52 T:3288 NOTICE: -->Python Interpreter Initialized<--
16:02:52 T:3288 ERROR: Error Type: <type 'exceptions.Exception'>
16:02:52 T:3288 ERROR: Error Contents: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
16:02:52 T:3288 ERROR: Traceback (most recent call last):
File "C:\Users\traesprit\AppData\Roaming\XBMC\addons\script.pypredefcom\addon.py", line 56, in <module>
Addon = xbmcaddon.Addon( id=os.path.basename( os.getcwd() ) )
Exception: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
(2012-10-06, 16:13)pewpew1 Wrote: I checked out the source from svn (trunk), but I get the below error, when I try to run it.
Code:WARNING: XFILE::CFileFactory::CreateLoader - Unsupported protocol(addons) in addons://more/executable.tbn
16:02:22 T:2592 NOTICE: -->Python Interpreter Initialized<--
16:02:22 T:2592 ERROR: Error Type: <type 'exceptions.Exception'>
16:02:22 T:2592 ERROR: Error Contents: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
16:02:22 T:2592 ERROR: Traceback (most recent call last):
File "C:\Users\traesprit\AppData\Roaming\XBMC\addons\script.pypredefcom\addon.py", line 56, in <module>
Addon = xbmcaddon.Addon( id=os.path.basename( os.getcwd() ) )
Exception: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
16:02:51 T:4472 WARNING: XFILE::CFileFactory::CreateLoader - Unsupported protocol(addons) in addons://more/executable.tbn
16:02:52 T:3288 NOTICE: -->Python Interpreter Initialized<--
16:02:52 T:3288 ERROR: Error Type: <type 'exceptions.Exception'>
16:02:52 T:3288 ERROR: Error Contents: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
16:02:52 T:3288 ERROR: Traceback (most recent call last):
File "C:\Users\traesprit\AppData\Roaming\XBMC\addons\script.pypredefcom\addon.py", line 56, in <module>
Addon = xbmcaddon.Addon( id=os.path.basename( os.getcwd() ) )
Exception: Could not get AddonPtr given a script id of XBMC. If you are trying to use 'os.getcwd' to set the path, you cannot do that in a Version: 2.0 plugin.
XBMC info: XBMC (11.0 Git:20120321-14feb09), Platform: Windows 7, 64-bit (WoW) Service Pack 1 build 7601. Built on Mar 21 2012 (compiler 1600)
Anyone else got this problem? If needed I can post the whole debug log - just thought the above snipplet was enough.