TED Talks update submission

init.zip (2.75 KB)



Added: Themes, Tags, Speakers, and All Talks sections

Missing: One person’s name doesn’t quite show up right. Jacek Utko video item won’t display.



All other files in bundle are unchanged.

Thanks! This is awesome! The TED and Academic Earth plugins are by far my favorite plugins so far and this really improves the TED interface. Hopefully it gets rolled into the official release.

Oh nice one Spaceman, thank you!

init.zip (2.72 KB)

Update. Jason Utko item now works. Can’t reproduce international name issue. I’m assuming I already fixed this and forgot about it.



I can’t think of anything else I’d like to add for this version.



Elan, is there anything else you’d like me to do before you release it as an update?

Caching is the only thing I think it needs. The key is to use HTTP.GetCached(url, cacheTime) where cacheTime is defined in seconds, e.g.



# Cache for 12 hours.<br />
CACHE_TIME = 3600*12 <br />
<br />
HTTP.GetCached(url, CACHE_TIME)



You use HTTP.GetCached wherever you previously used HTTP.Get and where you want caching to occur. This will make some of the paged requests instant when browsing within the cached time.

There's one additional workaround you need because of bug in v0 of the framework (it's fixed in v1, soon to be released), which is in your handler, do something like this:


Plugin.Dict["CacheWorkaround"] = datetime.datetime.now()



This is to ensure that the cache is saved.

Please feel free to email me (elan at plexapp dot com) when you're done or if you have questions. TED Talks is one of my favorites, and it was really exciting to see all the work you've done on it!

I'll get to work on this tomorrow.

The wait hasn't really bothered me since I have a form of progress indicator that shows up in the Terminal.
Now might be a good time to suggest the Framework provide a way of setting a progress bar in the Waiting for Response dialogue.

Wow, I spoke too soon. Check this out:

14:54:06.305106: com.plexapp.plugins.ted		 :   (Framework) Handling request :  /video/TED/dGFsa3MvbGlzdCRBbGwgVGFsa3M=/<br />
14:54:06.305587: com.plexapp.plugins.ted		 :   Count: 1<br />
14:54:06.309873: com.plexapp.plugins.ted		 :   Page count: 35<br />
14:54:06.543867: com.plexapp.plugins.ted		 :   (Framework) Response OK<br />
Reading 139295 bytes in the body, code is 200<br />
14:54:06.545045: com.plexapp.plugins.ted		 :   (Framework) Dictionary has been changed<br />
14:54:06.569456: com.plexapp.plugins.ted		 :   (Framework) Plugin dictionary pickled


Just populated 416 items spread across 35 pages in a quarter of a second :)

The caching is quite nice :slight_smile:

For anyone whose been following this thread: the latest version is now in the app store.

And working great, thanks again for the upgrade, spaceman!

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.