this is addon that installs/uninstalls a patch to help in blender addon development and add
a dependencies feature between addons.
it’s more intented to the blender pythonnist community and script developpers.
it removes common annoyances when scripting/enabling/bugging/disabling/reloading etc.
FEATURES :
adds a light dependency feature between addons :
. an addon can declare it needs another addon to be enabled to run.
. in the case the other addon is not started, it will be done right
before it (v0.7).
several parents can be declared, each with their versions.
. a 'parent' addon can't be disabled if it's currently used by one or
several other addons. an addon does not need any modification
to become a 'parent', only the 'child' needs a particular field
in bl_info
. the mod is fully compatible with normal addons.
. the 'childs' addons are fully compatible with the normal version.
. icons and new fields are displayed when an addon is either a 'child'
or a 'parent' addon.
. creation of a 'child' addon is quick : one new field in bl_info. (see below)
improvements for multi-modules addon development :
. get rid of the "already registered as a subclass" message when
unregister() was faulty.
. disabling then enabling an addon will reload and reread every module
of the addon not only the __init__ file (similar to F8 but for only
one module, or like the 'add a bug to __init__/reload/correct/reload'
trick)
. support dynamically created class (e.g. generated through exec)
without complaining.
addons can optionnally be disobedient :
at register() and unregister steps() an addon could decide to stay
active. this can be useful for cases where an addon has not finished
its job: it did not save a file, a modal op. is still running, he is
still performing a loop, or maybe the user needs to achieve something
before, etc..
to achieve this, register() and unregister() can return a simple string
explaining why the addon desobeys. the message will be reported in the
ui and in the console.
bugged addon enabled by default are not marked enabled any longer.
wip or unoffical scripts can be stored in a scripts/addons_sandbox folder
a location for you work before publication or to drop the scripts you find for
example here and that are not official or contrib.
misc. goodies :
ui report and icons are used along with console to provide info about
the cases above. messages from scripts can be displayed in various situation.
nerds friendly (some switches in init to play with)
the patch can be safely enabled and disabled from the user preferences addon tab.
a large README is provided with all of the info !
to link a parent and a child addon is simple. in the init file of the addon, one needs to ass a new field called dependencies
bl_info = {
"name":
"description":
[...]
<b> "dependencies" : 'Script Events (0,1)' </b>
}
for several parent addons :
"dependencies" [/B]: [ 'Script Events (0,1)', 'a second addon (1,2,3)' ]
as of 0.6 this patch is (from now) provided as an addon
download :
fork :
also available from the meta-androcto svn script collection at sourceforge.
can be used with graphicall builds (see nerds swicthes in README) at your own risk.
( but it’s not too risky.)
if you used v0.6, you should update. simply replace the addons_dependencies folder,
restart, apply, and restart again.
for prior patches (provided as is with the .dependencies extension) you should restore the original files them remove the modded files, then enable the addon (not mandatory but cleaner)
WARNING : it has been tested x 100 on XP, ubuntu 11.10 2.59, 2.60rc and 2.60 in various chaotic cases. everything should be ok for seven and mac else please report. LOTS of info in the readme and documented code.
I’m often on irc #blenderpython for support. in the worst cases, the trunk files are provided and their paths are written in the config file.