PyQt4 imports in Maya 2010, doesn't in Maya 2011

120 views
Skip to first unread message

Ofer Koren

unread,
Aug 23, 2010, 4:49:57 AM8/23/10
to python_in...@googlegroups.com
I've installed this a while ago, and I'm not sure what I should do now to make this work with 2011 as well.
I'm getting this error:


import PyQt4              # this works fine
import PyQt4.QtCore  # all the .pyd files are where they're supposed to be.

# Error: DLL load failed: The specified procedure could not be found.

# Traceback (most recent call last):

# File "<maya console>", line 1, in <module>

# ImportError: DLL load failed: The specified procedure could not be found. #



I'm sensing some kind of build/compile conflict... but hopefully someone can tell me what the easy fix would be?...



- Ofer
www.mrbroken.com

David Moulder

unread,
Aug 23, 2010, 5:34:40 AM8/23/10
to python_in...@googlegroups.com
2011 is compiled against Qt 4.5.3 and so you have to use that version of Qt.  PyQt's release visioning bears no relation to Qt's and the default downloads from riverbank are built against the latest stable Qt version. 4.6 I think.

Fortunately there are some very kind TD's out there that have already done the leg work and compiled the right Qt with the right Python and PyQt.

See Nathan Horne's blog for downloads.

http://nathanhorne.com/?p=229

-Dave




--
David Moulder
http://www.google.com/profiles/squish3d

Ofer Koren

unread,
Aug 23, 2010, 5:31:14 PM8/23/10
to python_in...@googlegroups.com

scottbvfx

unread,
Aug 23, 2010, 11:42:04 PM8/23/10
to python_inside_maya
This is a problem that I've been seeing for a while with Python and
PyQt (outside of Maya) for a while now. Several other people have
noticed it but Phil Thompson (PyQt creator) has yet to acknowledge
that its an issue. It seems to plague some machines and not others for
some unknown reason.

The only solution I've seen is to copy the DLLs from the PyQt4/bin
directory to PyQt4 (ex. PyQt4/bin/QtCore4.dll --> PyQt4/QtCore4.dll)
Its not an elegant solution but it should work. I haven't tried it
with Maya but it works with Python command line.

Cheers,
-Scott

Ofer Koren

unread,
Aug 24, 2010, 3:11:14 AM8/24/10
to python_in...@googlegroups.com
Looks like David's suggestion works as well (just verified now)

- Ofer
www.mrbroken.com


Reply all
Reply to author
Forward
0 new messages