using pyscripter for debugging plex plugins

Hi Folks,

 

I'm a linux boffin and have done a lot of scripting over the years, now trying to sharpen my python skills. I have been working with the IDE pyscripter (on windoze) which i really enjoy using. Now I would like to merge my python learning with my enjoyment of plex. I think a good learning avenue would be to take some of the plugins people have made in the past that no longer work and make the work again. I want to do this using pyscripter.

 

Now having had a bit of a bash around I see that many of the broken plugins source modules they expect to be present in the Python Path. For example they seem to all source modules from (remember im doing my dev on windoze) :-

 

\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Versions\

\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\

\AppData\Local\Plex Media Server\Plug-ins\Framework.bundle\Contents\Resources\Platforms\Windows\i386\Libraries\

 

Ideally i would like to make a wrapper projecct for pyscripter that creates the plex plugin sandbox with all the prereq modules needed to run these plugins.

 

My first attempt was to create my pyscripter project importing everything under \AppData\Local\Plex Media Server\Plug-ins and adding the above listed areas into my Python Path. However, when attempting to run the bootstrap.py from Resources\Versions\2\Python with a command line value of a valid plugin (ie "\AppData\Local\Plex Media Server\Plug-ins\ABCiView.bundle")

 

but I keep getting "ImportError: DLL load failed: The specified module could not be found." when it is trying to load "from lxml import etree, html, objectify".

I note these modules are pyd files under Resources\Platforms\Windows\i386\Libraries\lxml which should be found ok with my current Python Path.

 

Any thoughts anyone ?
 

Also, Is there a doc somewhere describing the implementation of the sandbox and what the runtime environment for plugins looks like ?

 

Regards Rep

seem to have found an answer to the dll error for myself.... running :- http://www.dependencywalker.com/   and loading etree.pyd I see that there are two dependencies missing.....

1) python26.dll (ah so using python2.7 wasnt really helping me - installed 2.6)

2) IESHIMS.DLL (part of internet explorer apparently... found it in c:\Program Files\Internet Explorer\.... added that to my path )

Now can load up bootstrap.py ok.... time to probe a little deeper ;-)

Let us know how it goes! Wonder if this could be done with Python Tools for Visual Studio as well...

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