pyblish_qml.host : Success. QML server available as pyblish_qml.api.current_server()
“main”, mod_spec)
TypeError: A constant property cannot have a WRITE method or a NOTIFY signal.
Traceback (most recent call last):
File “D:\pyblish\lib\Python37\lib\runpy.py”, line 193, in _run_module_as_main
File “D:\pyblish\lib\Python37\lib\runpy.py”, line 85, in run_code
exec(code, run_globals)
File "D:\pyblish\lib\Python37\lib\site-packages\pyblish_qml_main.py", line 6, in
from . import app
File “D:\pyblish\lib\Python37\lib\site-packages\pyblish_qml\app.py”, line 12, in
from . import util, compat, control, settings, ipc
File “D:\pyblish\lib\Python37\lib\site-packages\pyblish_qml\control.py”, line 16, in
class Controller(QtCore.QObject):
File “D:\pyblish\lib\Python37\lib\site-packages\pyblish_qml\control.py”, line 309, in Controller @QtCore.Property(bool, constant=True)
set constant=False, Python error:“this application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem."
# pyblish_qml.host : Installed event filter #
Using Python @ 'C:/Program Files/Autodesk/Maya2022/bin/mayapy.exe'
Using PyQt5 @ 'C:/Program Files/Autodesk/Maya2022/Python37/Lib/site-packages/PyQt5'
Targets: default
# pyblish_qml.host : Success. QML server available as pyblish_qml.api.current_server() #
# Result: <pyblish_qml.ipc.server.Server object at 0x000001C29C0FFBC8> #
Traceback (most recent call last):
File "C:\Program Files\Autodesk\Maya2022\Python37\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "C:\Program Files\Autodesk\Maya2022\Python37\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Program Files\Autodesk\Maya2022\Python37\lib\site-packages\pyblish_qml\__main__.py", line 6, in <module>
from . import app
File "C:\Program Files\Autodesk\Maya2022\Python37\lib\site-packages\pyblish_qml\app.py", line 12, in <module>
from . import util, compat, control, settings, ipc
File "C:\Program Files\Autodesk\Maya2022\Python37\lib\site-packages\pyblish_qml\control.py", line 16, in <module>
class Controller(QtCore.QObject):
File "C:\Program Files\Autodesk\Maya2022\Python37\lib\site-packages\pyblish_qml\control.py", line 309, in Controller
@QtCore.Property(bool, constant=True)
TypeError: A constant property cannot have a WRITE method or a NOTIFY signal.
uninstalling..
removing eventfilter..
removing callbacks..
# pyblish_qml.host : The eventFilter of pyblish-qml has been removed. #
Also, what is that UI you’ve screenshotted at the bottom? Can you take me through the steps to reproduce the problem? How do you launch Maya? Have you followed the steps here?
I tried to run the pyblish_qml demo and it generates the same error. I also tried it with python3 (c/python3) and it shows me the same error.
The screenshot is from the Pycharm(2023.2) package installation tool.
I followed the steps in GitHub that you shared, there I show you my python editor in Maya.
from pyblish_qml import api, show
api.register_python_executable("C:/Program Files/Autodesk/Maya2022/bin/mayapy.exe")
api.register_pyqt5("C:/Program Files/Autodesk/Maya2022/Python37/Lib/site-packages/PyQt5")
show()
I get the same issue in Maya 2022, which seems to run Qt 5.15.
I’ve updated the repository now, and added a script you can use to create a self-contained version of Python + PySide2 and Pyblish QML. Use it to (1) test that it works on your machine, by calling the generated pyblish-qml.ps1 script and (2) as reference for how to configure your environment to use this distribution.
It will create a new directory in your current directory, called pyblish-qml-dist/ with an appropriate Python interpreter, PySide and Pyblish library. You would point to this from e.g. Maya such that this is the interpreter and PySide version that runs the Pyblish QML UI, using the same environment variables as you’ll find in pyblish-qml.ps1.
Sorry for the ignorance, but I feel it’s better to ask than to die with the doubt haha. How do I run the script? I understand that it is a type of script that I can run with Windows PoweShell, but for some reason it doesn’t work for me.