Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DGModifier.disconnect and Undo #45

Closed
mottosso opened this issue Dec 5, 2020 · 0 comments · Fixed by #46
Closed

DGModifier.disconnect and Undo #45

mottosso opened this issue Dec 5, 2020 · 0 comments · Fixed by #46
Labels
bug Something isn't working

Comments

@mottosso
Copy link
Owner

mottosso commented Dec 5, 2020

For whatever reason, you can't disconnect and connect in the same "do_it" batch without breaking undo.

tx = cmdx.createNode("animCurveTL")
tx.keys(times=[1, 2, 3], values=[0.0, 1.0, 0.0])

tm = cmdx.createNode("transform")
tm["tx"] << tx["output"]

with cmdx.DagModifier() as mod:
  mod.disconnect(tm["tx"])
  mod.connect(tm["sx"], tm["tx"])

cmds.undo()
# Error: (kFailure): Unexpected Internal Failure
# Traceback (most recent call last):
#   File "C:/cmdx.py", line 5548, in undoIt
#     shared.undos[self.undo]()
# RuntimeError: (kFailure): Unexpected Internal Failure # 
@mottosso mottosso added the bug Something isn't working label Dec 5, 2020
mottosso added a commit that referenced this issue Dec 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant