mpfb2 icon indicating copy to clipboard operation
mpfb2 copied to clipboard

MPFB should check if a name is already taken before using it in rigify generate

Open gabrielmontagne opened this issue 3 years ago • 3 comments

It's not always, though. Normally not when I just go directly through the steps, but after a while of tweaking and adding assets. I'm trying to come with a reliable way to reproduce.

image

gabrielmontagne avatar Nov 14 '21 21:11 gabrielmontagne

Looking around, it seems to be in rigify, not in mpbf2. Hm.

gabrielmontagne avatar Nov 14 '21 22:11 gabrielmontagne

I know what it is. On the "generate rigify rig" dialogue I'm setting a name that's already used by an existing object (in my case, a mesh). All crashes from there onwards, rigify thinking it's operating on an armature, but it's actually a mesh (it's actually a mess : P ) .

I wonder if mpfb2 should or shouldn't check? It ends up being a runtime error so maybe it should, even if it's my fault somehow? Or maybe, when it generates the armature it should check the resulting name, in case it has a .001 or something?

Thinking out loud. I'd be fine if this is closed with a "problem between keyboard an chair" resolution. But still it'd be nice to get a warning instead of a crash.

gabrielmontagne avatar Nov 14 '21 23:11 gabrielmontagne

If it is as simple as checking if the name is already used by a different object, we might as well perform the check. It shouldn't take more than a few milliseconds.

joepal1976 avatar Nov 15 '21 06:11 joepal1976

I think this works as intended.

joepal1976 avatar Aug 22 '23 11:08 joepal1976