News for Plugin Developers

Do you have questions about writing plugins or scripts in Python? Meet the coders here.
Post Reply
User avatar
kgschlosser
Site Admin
Posts: 3595
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

News for Plugin Developers

Post by kgschlosser » Sun Apr 30, 2017 3:53 pm

When importing a library included with your plugin you will want to do your import of the library a little differently to make sure there are no issues if the user is running eg 0.5 and may have python installed and the same library installed in their python installation.

Code: Select all

from . import package
The reason for this is because EG 0.5 checks to see if there is a python installation and if there is will add that installations site-packages folder to the search path for the import mechanism. and if the user has the same library installed but maybe a different version or if you had to alter the library in some fashion to make it work properly with EG this will ensure it does not try to load the one from the python installation first.

Just wanted to throw that tidbit out there to help to minimize any development issues but to also help to minimize any bug reports you could possibly get for the plugin.
If you like the work I have been doing then feel free to Image

Post Reply