GitHub and converting tools to Maya 2017
Hey guys, I have multiple tools on github and have never converted them to Maya 2017 / Pyside. I see many of you have forked them to add that support.
What’s the best way to deal with this? Should I just update the tools to only work with PySide2? Is there an option through github to branch my own tool, or let people know that for older Maya support they need to grab up to a certain changelist?
> Should I just update the tools to only work with PySide2?
Might be an idea to use https://github.com/mottosso/Qt.py for backwards compatibility.
Comment by Toke Jepsen — 2018/03/16 @ 8:04 PM
That’s what we use internally at Epic. I don’t really want to rely on third party libs. Is this how most tools are doing it? Requiring that you grab this lib?
Comment by Chris — 2018/03/17 @ 3:23 PM
I would generally recommend you ship Qt.py with your application, such that you have no external dependencies, and use relative imports to ensure you get the exact version you expect. Example here: https://github.com/pyblish/pyblish-lite/blob/master/pyblish_lite/app.py#L8
Comment by mottosso — 2018/03/19 @ 5:17 AM
Looks like Nicolas Chaverou already put up a Pull Request that you could just accept https://github.com/chrisevans3d/skinWrangler/pull/13
It just adds this lib already.
Comment by Eric — 2018/03/19 @ 6:28 AM
I agree with Toke.
If you use pythons distutils packaging most TD’s won’t care what thirdparty libs you have since they can just run “python setup.py install”, i tend to do that or alternative i just manually include the Qt.py file in the repo. For artists of coarse i just include the source in the release.
Comment by David Sparrow — 2018/03/19 @ 8:36 AM
You can code for Pyside compatibility on import simply by doing this…
https://gist.github.com/ross-g/203a626bf4e5b48b37f9d37e60d623dc
The only real difference is that some objects were moved from QtGui to a new QtWidgets module. So if you code as if you were working in Pyside2 and just add those alias during import then it works with no third party dependencies.
Comment by ross-g — 2018/03/19 @ 5:19 PM
I’ll second Qt.py.
That’ll just let you run your tools with any version of Maya seamlessly
I’ve pull requested an updated version of skinWrangler using Qt.py as 3rd party a while ago, if you’d like to take a look
It’s pretty non intrusive and you can easily wrap this in Github using submodules
Comment by Nicolas — 2018/03/26 @ 7:35 AM