Scripting error message "Grouping level problem" .

Find out why the . goes before the /

Moderator: Paul Tuersley

Post Reply
davestewart
Posts: 114
Joined: March 10th, 2005, 5:50 am
Location: London, UK
Contact:

I've just moved a whole load of functions to run from a scripted UI, and I'm getting this error when running them:

After Effects warning: grouping level problem. Will attempt to rectify...

Does anyone know what this is all about? I'll hack away until I get somewhere, but if you know, please chip in...

Thanks,
Dave
davestewart
Posts: 114
Joined: March 10th, 2005, 5:50 am
Location: London, UK
Contact:

Ok - I think I've found out what it is:

If a function is called from a UI item (in this case a button), and there is a bug in the said function, it throws that error.

I have no idea why it doesn't speciy the error explicitly, or bring it up in the debugger - I can only assume AE is trying to be kind to both the end user, and the script writer's reputation, by not showing the innards of the script and compaining more loudly!

In the meantime, I shall be bullet-proofing my scripts OUTSIDE of a scripted UI.

But does anyone else have any more info??

Thanks,
Dave
User avatar
redefinery
Posts: 112
Joined: April 1st, 2005, 8:16 pm
Location: CA
Contact:

davestewart wrote:Ok - I think I've found out what it is:

If a function is called from a UI item (in this case a button), and there is a bug in the said function, it throws that error.
I don't know if it's solely because a callback function has a problem. I've had numerous bugs in those types of functions and didn't get this error. :-)

However, if I remember correctly, I have seen this error before when I was trying to work with layer properties incorrectly. Is your script doing something special with layer properties or traversing the property hierarchy? Maybe "grouping level" is referencing a problem accessin an indexed or named property group?

Jeff
davestewart
Posts: 114
Joined: March 10th, 2005, 5:50 am
Location: London, UK
Contact:

Yup.. I was iterating thorugh all comps, layers, and effects!

Hmmm.... the problem seems to have gone away now, and everything is worked as planned. I guess it's one of those temperamental things.

A bit annoying! I don't like it when I don't know why something isn't working!

Thanks for your input,
Cheers,
Dave
Paul Tuersley
Posts: 704
Joined: June 5th, 2004, 7:59 am
Location: London, UK

This may not be the only reason, but the error can be caused by having a beginUndoGroup without a corresponding endUndoGroup.

Paul T
davestewart
Posts: 114
Joined: March 10th, 2005, 5:50 am
Location: London, UK
Contact:

Thank Paul, i'll look into it...
zold

Paul Tuersley wrote:This may not be the only reason, but the error can be caused by having a beginUndoGroup without a corresponding endUndoGroup.

Paul T
... or if you run a script that errors within an 'undo block', then you might get an error for that, or the next time you run a script (because, perhaps, AE is in a way still 'holding on to' that undo group).

-cg
ckelley
Posts: 12
Joined: September 10th, 2004, 1:01 pm

I'm beginning to think this is the new "After Effects has encountered an error" from 6.0 reincarnated in script form. I have seen it for 2 or 3 other reasons from the ones listed above, including one that is completely unrelated to scripting - if you copy/paste child layers into a new comp without the parent I get this error sometimes. It's friggin' annoying and unclear... boo.
Post Reply