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

ls(sl=True, uuid=True) fails #423

Open
RobinScher opened this issue Jul 16, 2019 · 1 comment
Open

ls(sl=True, uuid=True) fails #423

RobinScher opened this issue Jul 16, 2019 · 1 comment

Comments

@RobinScher
Copy link

Maya command version cmds.ls(sl=True, uuid=True) returns a list of UUID strings:
Result: [u'BA2653C9-42AB-58FD-4206-009350A025B5', u'194E3BAD-4FAC-AD47-6FA3-9DBFEAFBBAC0']

PyMEL version pymel.ls(sl=True, uuid=True) fails with an error:
Error: MayaNodeError: file ...\pymel\core\general.py line 2306: Maya Node does not exist (or is not unique):: u'BA2653C9-42AB-58FD-4206-009350A025B5'

@RobinScher
Copy link
Author

Since the PyMEL ls command returns PyNode objects instead of strings, and PyNode objects have a method to get the uuid, it makes sense to simply ignore the uuid/uid flag to the ls command here. This is a simple change in core/general.py, add to the ls command (I put it at line 1079):

kwargs.pop('uuid', None)
kwargs.pop('uid', None)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant