Plugin and progressbar -> XBMC freeze/lockup
#1
Hi, I maintain a plugin (XOT-Uzg) and am running into some strange problem with showing progressbars.

When my plugin opens an URL it shows a progressbar. This however causes XBMC to completely freeze up. This is what is done by the script

- open an URL and shows a PB (it shows, it updates and disappears)
- parse the content fetched from the URL
- generate items and add them using addDirectoryItem
- call endOfDirectory

this all happens correctly, and then XBMC (testing using Windows) hangs and no results are shown.

Whenever I remove the PB it all works OK. Is it a bug?
Reply
#2
Could well be a bug. Which version are you running?

And why are you popping up a progress dialog? XBMC will handle that for you.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#3
jmarshall Wrote:Could well be a bug. Which version are you running?

And why are you popping up a progress dialog? XBMC will handle that for you.

I am using a Rev29326 SVN build (did it myself using VS2008 express).

I show the dialog, because opening an url could take some time (4-10 sec) and I want the user to wait patiently.

Besides that, the scriptversion of XOT-Uzg shows them at the same moments and I use the same python classes for the script and plugin.
Reply
#4
i've seen this kind of problem too in my plugins, don't know why it occurs, and hwy that's only sometimes...
Reply
#5
I created a small plugin that causes this problem:

Code:
import xbmcplugin, xbmc, xbmcgui
import time

pluginName = sys.argv[0]
handle = int(sys.argv[1])

item = xbmcgui.ListItem("test item")
item.setInfo("video", {"title": "test item", "PlotOutline": "just an outline"})                
ok = xbmcplugin.addDirectoryItem(handle, "%s?%s=%s" % (pluginName, 'variable', 'value'), item, isFolder=True)


uriPB = xbmcgui.DialogProgress()
uriPB.create('title', 'line 1 -')
time.sleep(0.2)
uriPB.update(int(25.1), 'line 1 /','line 2')
time.sleep(0.2)
uriPB.update(50, 'line 1 |','line 2')
time.sleep(0.2)
uriPB.update(75, 'line 1 \\','line 2')  
time.sleep(0.2)
uriPB.update(100, 'line 1 -','line 2')  
if uriPB.iscanceled()==False:
    print 'OK'
else:
    print 'NOK'
uriPB.close()

item = xbmcgui.ListItem("test item 2")
item.setInfo("video", {"title": "test item 2", "PlotOutline": "just an outline"})                
ok = xbmcplugin.addDirectoryItem(handle, "%s?%s=%s" % (pluginName, 'variable', 'value'), item, isFolder=True)

xbmcplugin.addSortMethod(handle=handle, sortMethod=xbmcplugin.SORT_METHOD_LABEL)
xbmcplugin.endOfDirectory(handle, ok)

If you click through this plugin a bit fast, it will eventually stall. If you comment the progressbar lines, it will continue without problems.
Reply
#6
i have the same problem with my bande annonce allocine plugin, when you go in a directory, if local db doesn't exist, if will built it and pop up a dialog progress during this time, then load info.

no problem if a local file exist, no progress dialog shown, but if there no local file, it will built it, but after dialog progress dissapear, xbmc will freeze.

jmarshall, sometime we need this dialog progress to display info we can't in default plugin progress, when no additem needed for example.
we can't modifiy default dialog plugin progress (?)

it's not platform dependant, tested on windows and linux. with svn version compilated 1st march
Reply
#7
i've manage to load without by adding item during the search instead of the dialog progress, on plugin dialogprogress, i can see the number of item increases but the progressbar doesn't grow, how can i do use it ?
Reply
#8
I wonder if it clashes with the busy dialog.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#9
things i remember is that is has worked !

i created my plugin 1st juanary, i've got sometime this error on my vista with latest svn, but never have the problem on my xp htpc which was an anterior revision.
i was thinking it was vista ...
Reply

Logout Mark Read Team Forum Stats Members Help
Plugin and progressbar -> XBMC freeze/lockup0