[Bf-python] Let Addons finf out if new release available...

Gaia Clary gaia.clary at machinimatrix.org
Mon Feb 22 16:51:13 CET 2016


Hi;

The following is about third party addons which are not
distributed together with Blender. So just you know in advance :)

== Here is the story: ==

Our Addon needs to be updated occasionally. We added a panel
into the Toolshelf where users now can simply click a button to
get informed if there is an update available. Eventually they get
the option to download the new version (if there is one).

However many of our customers have asked us if we can let
our Addon tell them instead about availability of a new release.

== And some ideas for getting this solved: ==

The best that i can currently think of is to let a window popup
when the user calls one of the central functions of the Addon
and when a new update is available. But this is sort of annoying.

So one other idea is to embed this into blender as follows:

1.) Add a new bl_info parameter, e.g.:

update: "http://my.website.org/addon/newest_version"

In the Addon panel add a new option "enable ask for update"
which is off by default and only available when the update
parameter has been specified.

2.) Blender starts a function in the background which runs over all
addons which have an update website and which are enabled.
and collects the newest available release infos from there and puts
this information into a file for later usage.

This background function can run maybe once per day or
once per week or whatever (customizable?)

3.) The current content of the list from step 2 is displayed on the
splash screen on startup of Blender. There the user can click on a
button which send them to the Addon Panel from where all further
action can be taken.

A solution like this does a few cool things imho:

- it does not at all disturb the user because it operates somewhere
   in the background. Even when it fails then the worst thing is there
   will be no update entries in the list.
- The user can control if an Addon asks for updates (to be enabled in the
   Addon panel, see above)
- The user can decide on demand to see the list (open the splash screen)
- The user gets this list on the Splash screen when Blender starts up

This is just an idea. Maybe this can be done much better.
Or it may be totally not acceptable. I do not know this
before i get your feedback :)

thanks
Gaia




More information about the Bf-python mailing list