• 1
  • 8
  • 9
  • 10(current)
  • 11
  • 12
  • 15
Your 1st Add-On: Hello World!
if you could provide a download link to your zipfile, we can have a look at it.
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
After spending 2 days banging my head on it, of course I find the solution just 30 minutes after I spam the forum... It seems that both the zip file AND main folder need to have version number appended to the names, like this: plugin.type.addonname-1.0.0. Previously I only appended "-1.0.0" to the zip file and not to the main folder in it Blush

Thanks ronie for a quick reply though...
Reply
Thanks royle..that helped a lot.
Reply
(2015-07-29, 16:44)royle Wrote: Hi, I'm new at developing for kodi and I stumbled upon an annoyance that I'm not able to fix myself, so please help. The quick version of my question is this: How do you compress an add-on so kodi doesn't complain about "incorrect strucure" on install?

The longer version of my problem is here -> I created my own add-on (audio/video plugin) but kodi won't let me install it via zip folder, telling me that the file has an incorrect structure even though I'm quite sure I did everything correct. If I extract the code to add-on folder, it works, kodi just doesn't like the zip... I also tried the Hello world sample and it only installs if i download the original zip file and feed it to kodi. As soon as I unzip/re-zip those same Hello world files, it breaks for some reason. I tried different programs (winzip, winrar, 7zip), operating systems (win 7, linux) and even all kinds of compression types (no/low/high compression) with no success. What am I missing here?

(2015-07-29, 16:50)ronie Wrote: if you could provide a download link to your zipfile, we can have a look at it.

(2015-07-29, 17:39)royle Wrote: After spending 2 days banging my head on it, of course I find the solution just 30 minutes after I spam the forum... It seems that both the zip file AND main folder need to have version number appended to the names, like this: plugin.type.addonname-1.0.0. Previously I only appended "-1.0.0" to the zip file and not to the main folder in it Blush

Thanks ronie for a quick reply though...

Can you guys elaborate on this? I download the hello world add-on and install from zip no problem. But if I extract the zip and then compress it again, the new zip file gives me the add-on structure error. Am I corrupting it when I compress/extract? I found out about this error because I took the existing hello world, did a few modifications (small), and then re-zip it for install. No luck.

I have tried changing the folder names (the zip and main folder) to versioning but that didn't help either.
Reply
Compare the archives with unzip -l
If I have helped you or increased your knowledge, click the 'thumbs up' button to give thanks :) (People with less than 20 posts won't see the "thumbs up" button.)
Reply
thanks. made a stupid mistake and was adding another folder by accident because i zipped the top folder. really dumb noob mistake.
Reply
Some time ago I wrote an example plugin to demonstrate how to create video plugins for Kodi. The plugin is very simple yet fully functional and the plugin code is provided with verbose comments. Maybe someone will find this example plugin useful. You can find it here: https://github.com/romanvm/plugin.video.example
Reply
tip:
use addDirectoryItems as that faster in bigger lists/slow hardware[/php]
http://mirrors.xbmc.org/docs/python-docs...ctoryItems

would be nice if you also included
http://mirrors.xbmc.org/docs/python-docs...em-setInfo
Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
Reply
So I m getting my first steps with python and playing with Kodi add ons. Seriously i get mad, because i dont get this "Hello World" add on started after packaging it as a zip file. What did i wrong?
Reply
(2015-08-31, 13:16)Martijn Wrote: tip:
use addDirectoryItems as that faster in bigger lists/slow hardware[/php]
http://mirrors.xbmc.org/docs/python-docs...ctoryItems

would be nice if you also included
http://mirrors.xbmc.org/docs/python-docs...em-setInfo

Thanks for the advises. All done.
Reply
(2015-08-08, 09:44)millatyme13 Wrote:
(2015-07-29, 16:44)royle Wrote: Hi, I'm new at developing for kodi and I stumbled upon an annoyance that I'm not able to fix myself, so please help. The quick version of my question is this: How do you compress an add-on so kodi doesn't complain about "incorrect strucure" on install?

The longer version of my problem is here -> I created my own add-on (audio/video plugin) but kodi won't let me install it via zip folder, telling me that the file has an incorrect structure even though I'm quite sure I did everything correct. If I extract the code to add-on folder, it works, kodi just doesn't like the zip... I also tried the Hello world sample and it only installs if i download the original zip file and feed it to kodi. As soon as I unzip/re-zip those same Hello world files, it breaks for some reason. I tried different programs (winzip, winrar, 7zip), operating systems (win 7, linux) and even all kinds of compression types (no/low/high compression) with no success. What am I missing here?

(2015-07-29, 16:50)ronie Wrote: if you could provide a download link to your zipfile, we can have a look at it.

(2015-07-29, 17:39)royle Wrote: After spending 2 days banging my head on it, of course I find the solution just 30 minutes after I spam the forum... It seems that both the zip file AND main folder need to have version number appended to the names, like this: plugin.type.addonname-1.0.0. Previously I only appended "-1.0.0" to the zip file and not to the main folder in it Blush

Thanks ronie for a quick reply though...

Can you guys elaborate on this? I download the hello world add-on and install from zip no problem. But if I extract the zip and then compress it again, the new zip file gives me the add-on structure error. Am I corrupting it when I compress/extract? I found out about this error because I took the existing hello world, did a few modifications (small), and then re-zip it for install. No luck.

I have tried changing the folder names (the zip and main folder) to versioning but that didn't help either.
Reply
Hey there. Did you find a solution for that problem? I ve got this too :-(
Reply
Hi.. Newbie here..

Anyone can correct my coding?..
I cant get icon (Thumbnail) in the list of my testing addons..

I tried both way, localhost and webhosting.. It didnt working.. Huhu please help and teach me..

Here is my code in "default.py"

Code:
import sys
import xbmcgui
import xbmcplugin

addon_handle = int(sys.argv[1])

xbmcplugin.setContent(addon_handle, 'movies')

art = xbmc.translatePath(os.path.join(ADDON.getAddonInfo('path'),'resources','media/'))
art2 = xbmc.translatePath(os.path.join(ADDON.getAddonInfo('path'),'http://123.456.789.10/resources','media/'))

url = 'http://123.456.789.10/movie1.mp4'
li = xbmcgui.ListItem('Movie_1', art+'Movie_1.jpg')
xbmcplugin.addDirectoryItem(handle=addon_handle, url=url, listitem=li)

url = 'http://123.456.789.10/movie2.mkv'
li = xbmcgui.ListItem('Movie_2', art2+'Movie_2.jpg')
xbmcplugin.addDirectoryItem(handle=addon_handle, url=url, listitem=li)

xbmcplugin.endOfDirectory(addon_handle)

Thanks in advance ^_^v
Reply
On the advice of team members, I have changed the Add-on to a Script.

https://github.com/zag2me/script.hello.world

The previous "Plugin" caused errors in the log because it was trying to create a virtual file tree.

A script is the way to go with something like this.

Coming soon. "Your First Video Tutorial"...

Happy coding!
Reply
Hello,

Im new to scripting in kodi, so i appreciate any help you can give me.

ok so i have installed an addon to kodi and im now editing it. i made a settings.xml in the resource folder and ive made 2 text boxes.

now what i want to do is pass a system command with the 2 strings as parameters.

my question is how can i pass these 2 strings as parameters in my python script?

i appreciate any help anyone can give me

Thank You
Reply
  • 1
  • 8
  • 9
  • 10(current)
  • 11
  • 12
  • 15

Logout Mark Read Team Forum Stats Members Help
Your 1st Add-On: Hello World!5