Stopping pyblish_qml process on Maya exit

Having taken this step back, I chose the least universal but most straightforward method and found a way. A scriptJob.


def on_application_quit():
    try:
        popen.kill()
    except OSError:
        # Already dead
        pass

cmds.scriptJob(
    event=["quitApplication", on_application_quit],
    protected=True
)

@derrick, if you pull you should be able to close Maya with the GUI open. As an added side-effect, the GUI now also closes when the host does.

$ cd pyblish-qml
$ git pull

This has now been fixed and released, see here.

Thanks @derrick for the continuous feedback, pyblish-qml is now better than ever and ready for 2017!

Big cheers and thanks from the artists here regarding the latest QML updates! :slight_smile: Processing seems faster and the improved stability (not having the connection refused errors anymore) has been a blessing. Sweet!