FAQ Database Discussion Community


python error: the parameter “pControls” must be either a Tuple or a List

python,python-2.7,xbmc
I need some help as I have got a problem with my code. I'm trying to get the control with each id to find the controls I'm looking for then remove the controls. When I try this: def clearEPG(self): program_button = [elem.control for elem in self.program_buttons] program_id = list() position_X...

A simple Script to extracting a zip file

python,unzip,zipfile,xbmc,kodi
Good Evening all, I think I'm not understanding the zipfile structure properly heres the code import xbmc import zipfile targetzip = xbmc.translatePath('special://home/userdata/addon_data/plugin.program.tester/test.zip') extractto = xbmc.translatePath('special://home/userdata/addon_data/plugin.program.tester/') zip = ZipFile(targetzip) zip.extractall(extractto) Any Ideas why Its not working?...

isReachable not working in android studio

android,xbmc
I am using XBMC android source code and now try to extract some code to new xbmc android project. When i try to connect to a ip address and check whether it is reachable using isReachable(), it is throwing a NetworkOnMainThreadException but same source code(in XBMC source code that is...

Python - shutil How to select multiple directories for deletion with similar names

python,glob,xbmc,shutil,kodi
I have a Directory called "master" inside I have sub directories as so. |master---- |test.directory.one |test directory.two |test.directory.three |test.directory.four |test.directory.five |this.directory.keep I would like to create a python script that deletes all the directories that start with test.directory and ignore anything else Thanks for you help. Any guidance is greatly...

XBMC/KODI error adding addon “structure incorrect”

add-on,xbmc,kodi
I'm following the KODI/XBMC hello world addon tutorial here and i downloaded the finished project from here but the problem is that i cannot edit it, as ever time I try to add a version that I edited onto KODI it gives me the error Addon does not have correct...

Java - Nested JSON objects

json,sockets,xbmc,kodi
I am trying to create a simple JAVA remote for XBMC/KODI and I think im doing ok so far (still early days) but I have hit a snag when I reached a nested JSON object. This is the original code I am converting to JAVA: {"jsonrpc": "2.0", "method": "Player.PlayPause", "params":...