GithubHelp home page GithubHelp logo

mikesilvo / script.skinshortcuts Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bignoid/script.skinshortcuts

18.0 18.0 21.0 4.3 MB

License: GNU General Public License v2.0

Python 100.00%

script.skinshortcuts's People

Contributors

abeksis avatar anxdpanic avatar bambi73 avatar bignoid avatar bobcratchett avatar canuma avatar dis90 avatar earch0 avatar enen92 avatar eng2heb avatar frodo19 avatar guilouz avatar hitcher avatar imgbotapp avatar iz8mbw avatar jayz2k avatar jeroenpardon avatar joaosagrath avatar marcelveldt avatar mergeandvary avatar mgonzales71 avatar mikesilvo avatar mvalec avatar phil65 avatar robweber avatar roee88 avatar roliverosc avatar sualfred avatar tomer953 avatar weblate avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

script.skinshortcuts's Issues

Submenu gets de-linked from main menu item

When changing the action for a main menu item, the submenu is getting de-linked - e.g. clicking on 'Edit submenu' takes you to a blank menu, even if the menu item previously had submenu items.

Internally, this is likely linked to the none type error you've been getting when editing menu items. When changing items, copies are made and properties are added to it - most likely, at some point the properties which tell the script which submenu was originally linked to it aren't getting copied across.

External Editing Doesn't Affect Proper Group

I'm trying to follow the process laid out here: https://github.com/mikesilvo164/script.skinshortcuts/blob/master/resources/docs/advanced/External%20editing.md, but hitting a snag...

The path I'm using is: RunScript(script.skinshortcuts,type=setProperty&property=myProperty&value=myValue&labelID=myLabelID&group=myGroup), being called from Python, using xbmc.executebuiltin(...).

But it appears that no matter what I pass into group=, or even if I omit it (as expected, in this case), it seems to only affect the mainmenu group, leading to a line like [u'mainmenu', u'myLabelID', u'myProperty', u'myValue'], in the generated .properties file.

Am I doing something wrong? Is this a bug? Is it not possible to affect items outside the main menu using this method?

[Bug?] Just Select method doesn't work from Python scripts

I'm attempting to create an add-on that features path choosing, and was looking to use the "Just Select" method of setting shortcuts/widgets for it. I've tried the following code in Python:

# broken into lines for easier readability
xbmc.executebuiltin("RunScript(script.skinshortcuts,type=widgets
    &showNone=False
    &skinWidgetType=autoWidgetType-1
    &skinWidgetName=autoWidgetName-1
    &skinWidgetTarget=autoWidgetTarget-1
    &skinWidgetPath=autoWidgetPath-1)")

And expecting the autoWidgetType-1, autoWidgetName-1, autoWidgetTarget-1, and autoWidgetPath-1 skin strings to be filled. After executing this line, and selecting my shortcut in the select dialog, these skin strings are never updated.

I have also tried the alternative method:

# broken into lines for easier readability
xbmc.executebuiltin("RunScript(script.skinshortcuts,type=shortcuts
    &skinLabel=autoLabel-1
    &skinAction=autoAction-1
    &skinList=autoSkinList-1)")

I am able to successfully set skin strings this way by setting the above RunScript(...) calls into the action of a skin shortcut, defined inside Kodi, or by manually editing the .xml file.

Similar methods from other add-ons seem to work, like from Skin Helper, successfully setting the skin string I've defined in the script call, even when called from Python.

For clarity, I am watching these skin strings in real-time via webinterface.devhelper.

propertyfallback Values Not Being Written Correctly

@anxdpanic Perhaps one more you can assist with fixing.

When troubleshooting the update, I noticed that propertyfallback values from my overrides.xml were being parsed correctly in the GUI, but not being written to the XML with the same values. The XML was always using the last fallback value with no attribute matching even though the match was present.

I believe this is due to how has_property_fallback ( https://github.com/mikesilvo164/script.skinshortcuts/blob/master/resources/lib/skinshorcuts/property_utils.py#L47 ) is called from each location.

My workaround for now is to place the following code at the top of the has_property_fallback function

def has_fallback_property(fallback_property, match_properties):
    if isinstance(match_properties, list):
        match_properties = dict(match_properties)
    ...

This change then causes the XML to be written with the same values the GUI displays.

Add enable addon functionality

With v19 there's a new built-in function for Kodi that allows skinners to add a direct button for enabling an addon. The skinshortcuts script can install an addon via the ::INSTALL:: tag, but it cannot enable an addon AFAICT. Would it be possible to add an ::ENABLE:: tag of some sorts in order to be able to let users enable a disabled addon like the skin helper script or some other script that can be used together with the skinshortcuts script?

Partically broken in kodi 19.3

When i'm trying to use this addon with "Pellucid" skin i'm getting error mentioned here. This issue can be fixed by commenting (or removing) this line self.getControl(7).setLabel(xbmc.getLocalizedString(222)) in "common_utils.py". I didnt look through your addon structure, so this action may cause another bugs.

P.S. Sorry for my English

Best wishes, eXoterr.

Opening "Customize main menu" dialog window throws a lot of errors.

Hi!

I'm using latest version of script.skinshortcuts, which is 1.1.5. Opening dialog window throws a lot of errors.
Please take a look on it:

2021-07-21 14:17:25.591 T:108033    INFO <general>: initializing python engine.
2021-07-21 14:17:25.753 T:107805    INFO <general>: Loading skin file: /home/piotr/.kodi/addons/skin.cosmic/xml/script-skinshortcuts.xml, load type: LOAD_ON_GUI_INIT
2021-07-21 14:17:25.795 T:108035   ERROR <general>: GetDirectory - Error getting /home/piotr/.kodi/userdata/library/video
2021-07-21 14:17:25.806 T:108035   ERROR <general>: GetDirectory - Error getting /home/piotr/.kodi/userdata/library/music
2021-07-21 14:17:25.812 T:108035   ERROR <general>: GetDirectory - Error getting upnp://
2021-07-21 14:17:25.817 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.817 T:108035   ERROR <general>: 
2021-07-21 14:17:25.817 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.817 T:108035   ERROR <general>: 
2021-07-21 14:17:25.817 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.817 T:108035   ERROR <general>: 
2021-07-21 14:17:25.817 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.818 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.818 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: Traceback (most recent call last):
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>:   File "/home/piotr/.kodi/addons/script.skinshortcuts/resources/lib/library.py", line 971, in playlists
                                                       for line in xmldata.getiterator():
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 
2021-07-21 14:17:25.819 T:108035   ERROR <general>: AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getiterator'
                                                   
2021-07-21 14:17:25.819 T:108035   ERROR <general>: 

script-skinshortcuts.xml

<?xml version="1.0" encoding="UTF-8"?>
<window>
    <defaultcontrol always="true">313</defaultcontrol>
    <controls>
        <control type="group">
            <centerleft>50%</centerleft>
            <centertop>50%</centertop>
            <height>880</height>
            <width>1800</width>
            <animation effect="fade" time="200">VisibleChange</animation>
            <control type="group">
                <control type="image">
                    <left>-2000</left>
                    <top>-2000</top>
                    <width>6000</width>
                    <height>6000</height>
                    <animation effect="fade" time="300">VisibleChange</animation>
                    <animation effect="fade" start="0" end="100" time="300">WindowOpen</animation>
                    <animation effect="fade" start="100" end="0" time="200">WindowClose</animation>
                    <texture colordiffuse="80FFFFFF">colors/black.png</texture>
                </control>
                <control type="group">
                    <control type="image">
                        <left>0</left>
                        <top>0</top>
                        <right>0</right>
                        <bottom>0</bottom>
                        <texture colordiffuse="dialog_tint">colors/white.png</texture>
                    </control>
                    <control type="image">
                        <left>0</left>
                        <top>0</top>
                        <right>0</right>
                        <height>70</height>
                        <texture colordiffuse="button_focus" border="2">colors/white70.png</texture>
                    </control>
                    <control type="label" id="500">
                        <left>40</left>
                        <top>0</top>
                        <right>100</right>
                        <height>70</height>
                        <font>font32_title</font>
                        <aligny>center</aligny>
                        <shadowcolor>black</shadowcolor>
                    </control>
                </control>
            </control>

            <control type="list" id="211">
                <description>Rules List Control</description>
                <left>0</left>
                <top>80</top>
                <width>550</width>
                <height>880</height>
                <onup>211</onup>
                <onleft>noop</onleft>
                <onright>9200</onright>
                <ondown>211</ondown>
                <scrolltime>0</scrolltime>
                <itemlayout width="550" height="70">
                    <control type="label">
                        <left>30</left>
                        <top>12</top>
                        <right>30</right>
                        <info>ListItem.Label</info>
                        <animation effect="fade" start="100" end="50" condition="String.IsEqual(ListItem.Property(skinshortcuts-disabled),True)">Conditional</animation>
                        <animation effect="slide" end="48" condition="!String.IsEqual(Window.Property(groupname),shutdown)">Conditional</animation>
                    </control>
                    <control type="image">
                        <bordersize>10</bordersize>
                        <width>70</width>
                        <height>70</height>
                        <texture>$INFO[ListItem.Icon]</texture>
                        <visible>String.Contains(ListItem.Icon,special://skin/extras/icons)</visible>
                        <visible>!String.IsEqual(Window.Property(groupname),shutdown)</visible>
                    </control>
                    <control type="image">
                        <bordersize>10</bordersize>
                        <width>70</width>
                        <height>70</height>
                        <texture>$INFO[ListItem.Icon]</texture>
                        <visible>!String.Contains(ListItem.Icon,special://skin/extras/icons)</visible>
                        <visible>!String.IsEqual(Window.Property(groupname),shutdown)</visible>
                    </control>
                </itemlayout>
                <focusedlayout width="550" height="70">
                    <control type="image">
                        <texture border="5" colordiffuse="button_focus">common/white.png</texture>
                    </control>
                    <control type="label">
                        <left>30</left>
                        <top>12</top>
                        <right>260</right>
                        <scroll>false</scroll>
                        <info>ListItem.Label</info>
                        <textcolor>red</textcolor>
                        <animation effect="fade" start="100" end="50" condition="String.IsEqual(ListItem.Property(skinshortcuts-disabled),True)">Conditional</animation>
                        <animation effect="slide" end="48" condition="!String.IsEqual(Window.Property(groupname),shutdown)">Conditional</animation>
                    </control>
                    <control type="image">
                        <bordersize>10</bordersize>
                        <width>70</width>
                        <height>70</height>
                        <texture>$INFO[ListItem.Icon]</texture>
                        <visible>!String.IsEqual(Window.Property(groupname),shutdown)</visible>
                    </control>
                </focusedlayout>
            </control>

            <control type="grouplist" id="9200">
                <left>0</left>
                <top>98</top>
                <width>527</width>
                <align>right</align>
                <itemgap>10</itemgap>
                <onright>9100</onright>
                <onleft>211</onleft>
                <onup>Control.Move(211,-1)</onup>
                <ondown>Control.Move(211,1)</ondown>
                <orientation>horizontal</orientation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,0)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,1)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,2)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,3)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,4)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,5)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,6)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,7)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,8)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,9)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,10)">Conditional</animation>
                <animation effect="slide" end="0,70" condition="Integer.IsGreater(Container(211).Position,11)">Conditional</animation>
                <control type="button" id="302" description="Delete">
                    <width>32</width>
                    <height>32</height>
                    <font/>
                    <texturenofocus>buttons/cross.png</texturenofocus>
                    <texturefocus colordiffuse="red">buttons/cross.png</texturefocus>
                </control>
                <control type="button" id="301" description="Add">
                    <width>32</width>
                    <height>32</height>
                    <font/>
                    <texturenofocus>buttons/plus.png</texturenofocus>
                    <texturefocus colordiffuse="red">buttons/plus.png</texturefocus>
                </control>
                <control type="button" id="303" description="Up">
                    <width>32</width>
                    <height>32</height>
                    <font/>
                    <texturenofocus flipy="true">buttons/down.png</texturenofocus>
                    <texturefocus colordiffuse="red" flipy="true">buttons/down.png</texturefocus>
                </control>
                <control type="button" id="304" description="Down">
                    <width>32</width>
                    <height>32</height>
                    <font/>
                    <texturenofocus>buttons/down.png</texturenofocus>
                    <texturefocus colordiffuse="red">buttons/down.png</texturefocus>
                </control>
            </control>

            <control type="group">
                <left>550</left>
                <top>80</top>
                <control type="grouplist" id="9100">
                    <onleft>9200</onleft>
                    <onright>noop</onright>
                    <width>1250</width>
                    <height>880</height>
                    <itemgap>0</itemgap>
                    <orientation>vertical</orientation>
                    <control type="togglebutton" id="313" description="Enable/Disable">
                        <label>$LOCALIZE[24022]</label>
                        <altlabel>$LOCALIZE[24021]</altlabel>
                        <include>DialogSettingButton</include>
                    </control>

                    <control type="button" id="401" description="Choose Shortcut">
                        <label>$LOCALIZE[32048]</label>
                        <visible>!String.IsEqual(Container(211).ListItem.Property(skinshortcuts-disabled),True)</visible>
                        <include>DialogSettingButton</include>
                        <visible>!String.EndsWith(Window.Property(groupname),.1)</visible>
                    </control>

                    <control type="button" id="307" description="Action">
                        <label>$LOCALIZE[31267]</label>
                        <label2>$INFO[Container(211).ListItem.Property(Path)]</label2>
                        <visible>!String.IsEqual(Container(211).ListItem.Property(skinshortcuts-disabled),True)</visible>
                        <include>DialogSettingButton</include>
                        <visible>!String.EndsWith(Window.Property(groupname),.1)</visible>
                    </control>

                    <control type="button" id="305" description="Label">
                        <label>$LOCALIZE[31268]</label>
                        <label2>$INFO[Container(211).ListItem.Label]</label2>
                        <visible>!String.IsEqual(Container(211).ListItem.Property(skinshortcuts-disabled),True)</visible>
                        <include>DialogSettingButton</include>
                    </control>

                    <control type="button" id="306" description="Icon">
                        <label>$LOCALIZE[31173]</label>
                        <visible>!String.IsEqual(Container(211).ListItem.Property(skinshortcuts-disabled),True)</visible>
                        <include>DialogSettingButton</include>
                        <visible>!String.IsEqual(Window.Property(groupname),shutdown)</visible>
                        <visible>!String.EndsWith(Window.Property(groupname),.1)</visible>
                    </control>

                    <control type="button" id="405" description="Submenu">
                        <label>$LOCALIZE[31170]</label>
                        <visible>String.IsEqual(Window.Property(groupname),mainmenu)</visible>
                        <visible>!String.IsEqual(Container(211).ListItem.Property(skinshortcuts-disabled),True)</visible>
                        <include>DialogSettingButton</include>
                        <visible>!String.EndsWith(Window.Property(groupname),.1)</visible>
                    </control>

                    <!-- Manage widgets -->
                    <control type="button" id="406">
                        <label>$LOCALIZE[31176]</label>
                        <include>DialogSettingButton</include>
                        <visible>String.IsEqual(Window.Property(groupname),mainmenu)</visible>
                    </control>

                    <!-- Select widget -->
                    <control type="button" id="312">
                        <label>$ADDON[script.skinshortcuts 32044]</label>
                        <label2>$INFO[Container(211).ListItem.Property(widgetName)]</label2>
                        <include>DialogSettingButton</include>
                        <visible>String.EndsWith(Window.Property(groupname),.1)</visible>
                    </control>

                    <!-- Widget sort by -->
                    <control type="button" id="502">
                        <label>$LOCALIZE[31177]</label>
                        <include>DialogSettingButton</include>
                        <enable>!String.IsEmpty(Container(211).ListItem.Property(widget)) + !String.IsEqual(Container(211).ListItem.Property(widget),WeatherWidget) + !Container(8000).IsUpdating</enable>
                        <visible>String.EndsWith(Window.Property(groupname),.1)</visible>
                        <onclick>SetProperty(chooseProperty,widgetSortBy)</onclick>
                        <onclick>SendClick(404)</onclick>
                    </control>

                    <!-- Widget sort direction -->
                    <control type="button" id="503">
                        <label>$LOCALIZE[31178]</label>
                        <include>DialogSettingButton</include>
                        <enable>!String.IsEmpty(Container(211).ListItem.Property(widget)) + !String.IsEqual(Container(211).ListItem.Property(widget),WeatherWidget) + !Container(8000).IsUpdating</enable>
                        <visible>String.EndsWith(Window.Property(groupname),.1)</visible>
                        <onclick>SetProperty(chooseProperty,widgetSortDirection)</onclick>
                        <onclick>SendClick(404)</onclick>
                    </control>

                    <!-- Widget limit items -->
                    <control type="button" id="504">
                        <label>$LOCALIZE[31179]</label>
                        <include>DialogSettingButton</include>
                        <enable>!String.IsEmpty(Container(211).ListItem.Property(widget)) + !String.IsEqual(Container(211).ListItem.Property(widget),WeatherWidget) + !Container(8000).IsUpdating</enable>
                        <visible>String.EndsWith(Window.Property(groupname),.1)</visible>
                        <onclick>SetProperty(chooseProperty,widgetLimit)</onclick>
                        <onclick>SendClick(404)</onclick>
                    </control>

                    <control type="button" id="310" description="Background">
                        <label>$LOCALIZE[31171]</label>
                        <label2>$INFO[Container(211).ListItem.Property(background)]</label2>
                        <visible>String.IsEqual(Window.Property(groupname),mainmenu)</visible>
                        <visible>!String.IsEqual(Container(211).ListItem.Property(skinshortcuts-disabled),True)</visible>
                        <include>DialogSettingButton</include>
                        <visible>!String.EndsWith(Window.Property(groupname),.1)</visible>
                    </control>

                    <control type="button" id="308">
                        <include>DialogSettingButton</include>
                        <label>$LOCALIZE[31175]</label>
                        <visible>!String.EndsWith(Window.Property(groupname),.1)</visible>
                    </control>
                </control>
            </control>
            <!-- Hidden controls -->
            <control type="button" id="404">
                <visible>false</visible>
            </control>
            <control type="wraplist" id="8000">
                <left>-1000</left>
                <top>-1000</top>
                <width>1</width>
                <height>1</height>
                <itemlayout height="1" width="1" />
                <focusedlayout height="1" width="1" />
                <content>$INFO[Container(211).ListItem.Property(widgetPath)]</content>
            </control>
            <!-- Unused controls -->
            <control type="button" id="111">
                <visible>false</visible>
            </control>
            <control type="button" id="309">
                <visible>false</visible>
            </control>
        </control>
    </controls>
</window>

Any help is appreciated a lot! Thanks in advance! :)

gui.py tries to import itself, fix included

Ran into this when selecting "Manage submenu" in the menu editor.

ERROR : EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <class 'ModuleNotFoundError'>
Error Contents: No module named 'gui'
Traceback (most recent call last):
File "/dvb/kodi.config/addons/script.skinshortcuts/resources/lib/gui.py", line 1951, in onClick
import gui
ModuleNotFoundError: No module named 'gui'
-->End of Python script error report<--

Fixed by deleting line 1951: import gui
And modifying the line after from:
ui= gui.GUI( "script-skinshortcuts.xml", CWD, "default", group=launchGroup, defaultGroup=launchDefaultGroup, nolabels=self.nolabels, groupname=groupName )
to:
ui= GUI( "script-skinshortcuts.xml", CWD, "default", group=launchGroup, defaultGroup=launchDefaultGroup, nolabels=self.nolabels, groupname=groupName )

Fix was provided by AnonTester on the Kodi forum.

Hash file not saving/updating md5

Need to encode hash to prevent Unable to generate hash errors and it causes a build loop due to the .hash file not updating.

For me it stays at 8c7dd922ad47494fc02c388e12c00eac

[Bug] Kodi Widgets crashes on some skins.

Sorry for making this an issue but skins like OSMC or Aeon Nox: SiLVO crash with widgets made with the addon seren.

To reproduce this issue, im using the skin osmc for example to reproduce this.

  1. Download Seren from Nixgates Repository
    https://nixgates.github.io/packages
    1
  2. Go to the addon configuration settings into seren and go to shortcuts and click Toggle Re-Use Language Invoker that disables it.
    2
  3. Now go to Configure skin and go Customize main menu and go to videos tab
    3
  4. Now that your in the default Videos tab, go to Manage Widgets
    4
  5. Now that your in Manage Widgets, Click Select Widget
    5
  6. Go to Addons > Video add-ons > Seren > Discover Movies > Most
    Popular
    6
  7. Click Use as widget and the hit done.
    7
  8. Hit Backspace a few times and wait for 5 sec
    8
  9. Restart your kodi 5 times until you see a crash in one of them.
    9

Sorry this takes time to reproduce and here are some logs i went thru and some crash logs on OSMC and Aeon Nox: SiLVO

Aeon Nox: SiLVO:
kodi_stacktrace-19.0 Git_20210218-f44fdfbf67-20210414-040121.txt
kodi_stacktrace-19.0 Git_20210218-f44fdfbf67-20210414-040251.txt
kodi_stacktrace-19.0 Git_20210218-f44fdfbf67-20210414-040259.txt
kodi_stacktrace-19.0 Git_20210218-f44fdfbf67-20210414-042157.txt
kodi_stacktrace-19.0 Git_20210218-f44fdfbf67-20210414-042205.txt
kodi.log
kodi.old.log

OSMC:
kodi_stacktrace-19.0 Git_20210218-f44fdfbf67-20210414-024815.txt
kodi.log

v2.0.0 and v2.0.1 break Kodi on Apple TV

I have Kodi Matrix 19 on Apple TV 4K running Arctic Horizon or Arctic Zephyr Reloaded skins. Skin Shortcuts v1.1.5 works fine. When the Skin Shortcuts gets updated to v2.0.0 or v2.0.1, it causes an error and the skin will no longer refresh with customization changes. And if I change between the skins or update either skin to newer versions of the skins, Kodi then becomes completely unusable - it just loads with a blank home screen and I'm unable to do anything. My only recourse then is to restore from a backup using Xcode on a Mac connected to the Apple TV.

Possible conflict with skin helper service

I have a very strange problem. When I enter in kodi settings through skin shortcuts and then in one of the addons that I use to watch movies, the skin helper service doesn't start, more precisely, no meta data that goes through shs. If I get inside menu through the blade menu in my skin then everything works normally. Also if I get into some hub that is made through skin shortcuts shs does not run more precisely again there is no infos (ratings, studio logos, cast...). What's the problem here?

[Bug/Request] Pass InfoLabel as Widget Label

I'm currently working on add-on which populates a window property in order to have a dynamic title for one of its menu items. The title for the item looks something like $INFO[WIndow(10000).Property(my_property)]. Unfortunately, since this InfoLabel is evaluated during the time that the Skin Shortcuts dialog is building the list of items, the "evaluated" label appears to get passed through as widgetName.

If there any way to have this InfoLabel remain intact when set as widgetName? Ideally, the folder inside the selector dialog would show the value of the InfoLabel (as is accomplished on https://github.com/mikesilvo164/script.skinshortcuts/blob/a849e64a56aae7eebd3207583dc9954cae3b77b9/resources/lib/library.py#L548-549), but the final widgetName that gets used as the label for the widget would be the "unparsed" InfoLabel.

Is this possible?

WidgetTarget Empty for Playlists

@anxdpanic Perhaps you may be able to assist.

In troubleshooting why some widgets now seem to be broken for my skin, I noticed that the widgetTarget is coming back empty. I traced the changed behavior down to: 12562d2#diff-3eb7af7688749ce58a2bcec5231231baf7ed546fc81f4f2c9426ba1bc5eefc3bR1157 . The media_content is being set to an empty string on each line iteration of the xsp parsing. This causes the variable to be blanked out before it is read for the line.tag=="name" check happens. I am not sure why the media_content variable needs to be set to an empty string, but the media_library does not, but I believe the code needs to be changed to something like:

                        for line in iterator:

                            if line.tag == "smartplaylist":
                                media_content = ""

around line 1251 in library.py

This change causes the media_content (and therefore the widgetTarget) to get set correctly.

BUG: v2.0.1 contains typo in parameter name for ShowDialog

Additional Properties not saved

Setting menu icon, background and infoline works on Py2 but not Py3

Icon change works for main menu but management dialog doesn't update image.

$PYTHON evaluations using 'in' is reversed, breaks a few skins (template.xml)

The documentation states:

Whilst 'in' is available, for technical reasons its operation is reversed, so if you want to know if x is in y, you'd use if y in x.

However, after the py3 conversion, this is doubly reversed back to if x in y.

This does break some skins like Aura and AuraMOD, the latter of which we used a workaround to prevent this issue, see this commit of skin.auramod (Kodi 19 migration status: WIP)

For example in Line 91 the existing code was:

$PYTHON['true' if widgetPath in 'plugin:' else 'false']

and the two methods to make this line work again are:

1 - $PYTHON['true' if 'plugin:' in widgetPath else 'false']

2 - $PYTHON['true' if widgetPath == 'plugin:' else 'false']

We used method 2 for future-proofing if this addon (script.skinshortcuts) is fixed and makes the python a little easier to read.

If this issue is fixed, it would prevent the need for other skins' shortcuts to be fixed, for example the original skin.aura by jurialmunkey and the respective Aura Kodi 19 port currently underway by kcook98765

[Meta] Status of the Add-on

I'm currently a maintainer of @marcelveldt's repository, under @kodi-community-addons, where I understand many previous versions of this add-on have been served from in the past.

As this fork appears to be the most up-to-date, I'm simply trying to reach out and find the status of this project. I understand that it is being (or has been?) converted to Python 3, in preparation for Kodi Matrix and beyond... but is this the "official" version now? Are there plans for ongoing support for Kodi Leia and below? If not, which version would you recommend using?

Is this version on a repo for easy installation? Will it be merged to Kodi's official repository? If this is to be the successive version to whatever is in the official repo and in repository.marcelveldt, has there been thought given to the previous two questions?

Is this repo the best place for other developers to submit PRs or issues?

Include rebuild not triggered after template changes

I've come across a very strange issue mentioned here on the forum already: https://forum.kodi.tv/showthread.php?tid=178294&pid=3026461#pid3026461

When the template.xml file has been changed, the script used to rebuild the home menu include.xml when first firing up Kodi after the changes under v18 (with Python v2 code). Now, with v19 and Python v3, it doesn't anymore. The rebuild is only triggered, if you go to the customization dialog, change an item and return to whatever window features the script rebuild line in an onload... I'm using this rebuild line that used to work just fine:

<onload condition="System.HasAddon(script.skinshortcuts)">RunScript(script.skinshortcuts,type=buildxml&amp;mainmenuID=9000&amp;group=mainmenu&amp;levels=1&amp;options=noGroups)</onload>

Is there something wrong with the script which prevents an automatic rebuild once the template.xml code has been changed?

It's vital that this works as it leads to empty home menus for users of my skin as I reworked the way colours are selected and shown via variables. The template.xml uses those new variables, but the script doesn't rebuild the home menu include file automatically to reflect that change - it leads to this: https://discourse.osmc.tv/t/testing-kodi-v19-builds-for-vero-4k-4k/89151/499?u=chillbo

Inbuilt functions for generating playlists based on path do not work.

Skin Shortcuts has long offered the option of selecting a video source, then choosing to create a shortcut to this, and choosing to either create a link to the relevant library path, or creating a smart playlist (with the created playlist located in the Skin Shortcuts/Addon_data path), to either include or exclude files from the path selected.

I've read multiple reports that this functionality is broken in current Kodi versions (18+) and so either needs fixing (probably not - I'm presuming the underlying issue comes from a change in how Kodi loads playlists, especially those in a weird path such as ours) or removing.

script.skinshortcuts doesn't work in Kodi 19.3 Matrix with Pellucid skin - Can I install a prerelease to try to fix this?

I've installed the Pellucid skin on my Kodi 19.3 Matrix instance, which runs as an app on my nVidia SHIELD.

When I edit Pellucid's menu items and try to assign an action to a custom menu item (e.g. open one of my favorites), a window appears, titled Install Widget Provider, but the window only contains the OK and Cancel buttons. I would expect to be able to select something, but the window contains no items at all.

I've seen that Pellucid has a dependency on script.skinshortcuts; my guess is that the latest stable 1.x release is incompatible with Kodi 19.3.

Is this correct?

Would I be able to fix this behavior by installing a script.skinshortcuts prerelease (e.g. 2.0.0.alpha08)?

Thank you very much for your help!

Many errors using with LibreElec Matrix version

Hardware: Raspberry Pi 4
SO: LibreElec Milhouse #414. Updated from 9.2 stable (with Kodi v18)
Kodi version: v19 (Matrix)
Skin: skin.aura

All the time kodi shows me a skinshortcuts add-on error. The settings for widgets on "Customization home menu" not working, but widgets in the main menu works ok. I can't edit widgets settings.

I know that all this works are in alpha versions but, maybe these logs will help to improve this fantastic tool :)

Thanks for effort and gratz for your work!

New Itens

Since Retroplayer was introduce in kodi, we have two more Itens:

Games Addons
Games Folders (basically the same as image sources)

Can you please add these two itens?

Cheers

Help with Main Menu browsing

@BobCratchett
Not sure if you have time to help with this or if this is the best place to ask you but I am having an issue with the main menu. I'm hoping you can advise on the best course of action.
Relevant forum post.

I am defining the custom grouping for everything in the menu but I did not think of browsing through it like, with genres for example.

When I replace the video library section HERE with
<content>video</content>
Then all the > items are empty. If I completely delete all custom grouping then they work correctly.

Any advice?

Thanks

AttributeError: 'NoneType' object has no attribute 'getProperty'

Tried to debug, but running into trouble straight away.

The log code is still broken in multiple places - it's (partially) fixed in xmlfunctions:

def log(txt):
    if ADDON.getSetting( "enable_logging" ) == "true":
        if sys.version_info.major == 2:
            if isinstance (txt,str):
                txt = txt.decode('utf-8')

        message = u'%s: %s' % (ADDONID, txt)

        if sys.version_info.major == 3:
            xbmc.log(msg=message, level=xbmc.LOGDEBUG)
        else:
            xbmc.log(msg=message.encode('utf-8'), level=xbmc.LOGDEBUG)

(but shouldn't is be if not isinstance - if it's not already plain text rather than unicode, decode it to plain text...? - I could well be wrong!) That needs to be every instance of def log. Then I should be able to see what I'm doing.

(Minor issue also, the string for 'Enable debug logging' in settings.xml has been changed at some point so now reads something about widgets.)

I'll make the changes locally, then see if I can recreate your problem.

Button 308 Reset Shortcuts Error

@anxdpanic Been doing some testing and ran into a bug.

-->Python callback/script returned the following error<--
 - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <class 'AttributeError'>
Error Contents: 'DataFunctions' object has no attribute 'labelIDList'
Traceback (most recent call last):
 File "C:\Users\mikes\AppData\Roaming\Kodi\addons\script.skinshortcuts\resources\lib\skinshorcuts\gui.py", line 1472, in onClick
original_label_id_list = self.data_func.labelIDList
AttributeError: 'DataFunctions' object has no attribute 'labelIDList'
-->End of Python script error report<--```

Full Debug Log [HERE](https://paste.kodi.tv/cibuqadixi.kodi)

Thanks again for the work on the script! Don't understand most of it lol

Load cached widget contents on startup to improve startup time

On low-end systems starting extra python processes is slow. Lots of widgets which point at extra plugins all required to load the initial widgets creates processes, CPU and memory churn and results in minutes to see your first widget appear sometimes.

I recently added support for a cache feature on AutoWidget which saves a json file of a widgets contents so that on startup this is initially loaded and no additional plugins are loaded. Then a background thread will refresh each widget one by one. this reduced startup time a fair amount but a autowidget process is still loaded for each widget on startup, limiting how fast it can be. On my system this is still 1min from the kodi startup screen.

If similar caching was instead implemented in skinshortcuts the startup time would be even faster because no additional addons are loaded on startup. You would be able to browse your widgets while they are getting updated in the background. On a high-end machine the background updating would still be fast.

Playlist - incorrect action

When choosing action for menu, then selecting a playlist, then choosing to 'Display' it, the action is wrong: ::PLAYLIST>video::

The actions with ::'s around them are used internally by the script, so at some point in library.py, this isn't getting translated by the script into an actually valid action.

Removing backwards compatibility...

Two comments regarding the removing backward compatibility branch...

(1) Docs - at least one case where the docs probably had incorrect markup, but the update removes the link entirely rather than corrects it - for example resources/docs/advanced/Overriding icons.md - line 49.

(2) Is the script going to be limited to a minimum Kodi version? For various reasons, the idea has always been to support as older a version of Kodi as possible. Hence why we have $ISEMPTY, rather than the (now) String.IsEmpty (for example, default.py line 144.). It's not a bad idea to do so, but, if so, you need to ensure that the upgrades work from any version of Kodi previous to the minimum version you're specifying with this version / the previous version (it was probably a really bad decision early on, but I decided rather than try to maintain a number of versions of the script for a number of Kodi versions - particularly when the team was promoting 'rero' which they seem to have dropped - it was going to be easier to maintain one version of the script that supported a number of versions of Kodi...)

You also are almost certainly going to want to do a minor pint bump (x.Y.x), rather than a revision point bump (x.x.Y) - it might seem inconsequential, but it really does make sense when you're making breaking changes.,

I can't see any particular issues, but you need to pay particular attention to dataFunctions.py/upgradeAction(), especially if you're only going to support Kodi version x and above in a particular version of the script (and, if you wanted a real challenge to get your python skills in shape ... this would be so much better with the necessary upgrades being defined in the overrides.xml, rather than in python itself...)

Weblate and Add-on Submission

@mikesilvo164

When you have a chance, I need a few things added from your side on GitHub.

To add this script to Weblate for translations I need a webhook added to this repository.

For automated add-on submission to Kodi's Official Repository I need a token/secret added to this repository.

  1. Create a Personal Access Token with repo scope, and save it somewhere private for future use.
    https://github.com/settings/tokens

  2. Add that token to this repositories secrets with the name ADDON_SUBMISSION_TOKEN https://github.com/mikesilvo164/script.skinshortcuts/settings/secrets/actions

If you have any questions, don't hesitate.
Cheers!

Management Dialog control 307 cannot be disabled

When using the Management Dialog, setting <enable>false</enable> on control 307 "Change shortcut action" does not disable it and allows the user to still be able to use the control.

Scenario:
Trying to disable all controls except 305 "Change Shortcut Label" by using <enable>!String.IsEqual(Container(211).ListItem.Label,&lt;None&gt;)</enable> to ensure user enters a label before doing anything else. The other controls like 306 & 405 get disabled/enabled properly but 307 does not behave.

image

Tested on:

  • Kodi 19.4 release build
  • script.skinshortcuts v2.0.3

[Bug] Kodi crashes when using version 2.0.0 or higher

I have been using version 1.1.5 for a long time because since version 2.0.0 I have a problem with Kodi crashing when using addons that use arrow. Yes I know, the answer will probably be, what does it have to do with skin shortcuts. But this happens at the moment I install the latest version 2.0.3 or any version since 2.0.0. The message is always the same and the Kodi crash happens. When I use version 1.1.5 everything is perfectly fine. What is this about? What is so different about version 2.0.0 when this happens?

2023-06-26 22:53:35.484 T:8380    error <general>: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                                    - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                                   Error Type: <class 'AttributeError'>
                                                   Error Contents: 'datetime.timedelta' object has no attribute 'timestamp'
                                                   Traceback (most recent call last):
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.embuary.info\default.py", line 7, in <module>
                                                       from resources.lib.helper import *
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.embuary.info\resources\lib\helper.py", line 15, in <module>
                                                       import arrow
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\__init__.py", line 2, in <module>
                                                       from .api import get, now, utcnow
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\api.py", line 12, in <module>
                                                       from arrow.arrow import TZ_EXPR, Arrow
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\arrow.py", line 34, in <module>
                                                       from arrow import formatter, locales, parser, util
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\parser.py", line 26, in <module>
                                                       from arrow.util import next_weekday, normalize_timestamp
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\util.py", line 6, in <module>
                                                       from arrow.constants import (
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\constants.py", line 16, in <module>
                                                       _MAX_TIMESTAMP = datetime.max.timestamp()
                                                   AttributeError: 'datetime.timedelta' object has no attribute 'timestamp'
                                                   -->End of Python script error report<--

2023-06-26 22:53:34.860 T:7540    error <general>: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                                    - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                                   Error Type: <class 'AttributeError'>
                                                   Error Contents: 'datetime.timedelta' object has no attribute 'timestamp'
                                                   Traceback (most recent call last):
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.skin.helper.widgets\plugin.py", line 9, in <module>
                                                       import main
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.skin.helper.widgets\resources\lib\main.py", line 17, in <module>
                                                       from metadatautils import MetadataUtils
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.metadatautils\lib\metadatautils.py", line 10, in <module>
                                                       import helpers.kodi_constants as kodi_constants
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.metadatautils\lib\helpers\kodi_constants.py", line 10, in <module>
                                                       from .utils import KODI_VERSION
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.metadatautils\lib\helpers\utils.py", line 13, in <module>
                                                       import arrow
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\__init__.py", line 2, in <module>
                                                       from .api import get, now, utcnow
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\api.py", line 12, in <module>
                                                       from arrow.arrow import TZ_EXPR, Arrow
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\arrow.py", line 34, in <module>
                                                       from arrow import formatter, locales, parser, util
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\parser.py", line 26, in <module>
                                                       from arrow.util import next_weekday, normalize_timestamp
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\util.py", line 6, in <module>
                                                       from arrow.constants import (
                                                     File "C:\Users\Marko\AppData\Roaming\Kodi\addons\script.module.arrow\lib\arrow\constants.py", line 16, in <module>
                                                       _MAX_TIMESTAMP = datetime.max.timestamp()
                                                   AttributeError: 'datetime.timedelta' object has no attribute 'timestamp'
                                                   -->End of Python script error report<--

Skinshortcuts error

I often get this error when kodi loading. Skinshortcuts 2.0.3.

2023-07-13 14:24:05.878 T:20208   error <general>: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                                    - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                                   Error Type: <class 'xml.etree.ElementTree.ParseError'>
                                                   Error Contents: no element found: line 1, column 0
                                                   Traceback (most recent call last):
                                                     File "C:\Users\marko\AppData\Roaming\Kodi\addons\script.skinshortcuts\resources\lib\entry_point.py", line 16, in <module>
                                                       script.route()
                                                     File "C:\Users\marko\AppData\Roaming\Kodi\addons\script.skinshortcuts\resources\lib\skinshorcuts\skinshortcuts.py", line 78, in route
                                                       route_method()
                                                     File "C:\Users\marko\AppData\Roaming\Kodi\addons\script.skinshortcuts\resources\lib\skinshorcuts\skinshortcuts.py", line 83, in route_buildxml
                                                       self.xml_func.build_menu(self.MENUID, self.GROUP, self.LEVELS,
                                                     File "C:\Users\marko\AppData\Roaming\Kodi\addons\script.skinshortcuts\resources\lib\skinshorcuts\xmlfunctions.py", line 71, in build_menu
                                                       tree = ETree.fromstring(contents)
                                                     File "C:\Program Files\Kodi\system\python\Lib\xml\etree\ElementTree.py", line 1321, in XML
                                                       return parser.close()
                                                   xml.etree.ElementTree.ParseError: no element found: line 1, column 0
                                                   -->End of Python script error report<--

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.