registering addons changde SVN 30975

Hi,
I just realized, that registering (your) addons has changed in
the latest version (Windows 32 Vista at my home: of today SVN 30975)

Indeed. Lots of scripts seemt to be dead now, and when open the user prefs, blender hangs. I wil revert back to before that change.

If you look to the addons (included), in fact it has become ‘clearer’ (=easier) …

Oh my version does not hang! Changed to the new way of my own addon it worked nicely.

just recompiled this morning and experienced 2 changes with addons…

it seems that if an add-on tries to register and it is already registered blender now kicks up a fuss.

also within classes of bpy.types.Operator blender ‘forgets’ that bpy has already been imported within the execute block so none of the bpy.ops work at all unless you do…

def execute(self, context):
    import bpy
    ...

not sure if this is a bug or an odd change to the api?

You don’t have to call bpy.types.register() anymore for regular operators (they get automagically registered by the subclassing stuff apparently) and the addons need a little extra love for re-registering or something like that.

The ‘import bpy’ in the functions should be fixed now (per Campbell) – if it’s not then it’s a bug.