I don’t really have a clear answer to this, but I will share what I have.
Using your example, this is when I get the “unknown error” problem:
For me “MACTEST-1” would be a subassembly to which there has been applied an assembly-extruded-cut from a different subassembly (outside MACTEST-1), and MACTEST-1 would include parts that were suppressed before updating the equation, but unsuppressed after updating the equation (or perhaps the other way around), through feature-suppress-equations that changed between “suppressed” and “unsuppressed” when, using your example, Length was assigned to 90.
I guess, that the point is the combination of MACTEST-1 having feature-suppressions that change, MACTEST-1 is dependent on things external to itself, and MACTEST-1 not being open when its equation is updated. This combination cannot be handled by the system. If I remove the assembly-extruded-cut feature, the problem goes away.
This problem is irrelevant when manipulating through the user interface, since the equation manager cannot be opened if its component isn’t opened or chosen for edit first.
Note that in the code swEquationMgr is not the equation manager used in the equation assignment.
Also note that the documentation uses calls to SetEquationAndConfigurationOption instead of updating the equation with a simple assign statement. Perhaps we should consider direct assignment of equations to be obsoleted by this new variant. However, for me it didn’t help to use that call instead.
I use SW 2014 SP 5.0.