[PyQt] Python 3 import error
Thorsten Kampe
thorsten at thorstenkampe.de
Thu Dec 2 11:24:54 GMT 2010
Hi,
I'm trying to port a PyQt4 application from Python 2 to Python 3. The
application works fine with the latest Python 2 (2.7.1) but not with
Python 3.1.2:
Traceback (most recent call last):
File "my_application.pyw", line 10, in <module>
import resource.ui
File "F:\[path]\resource\ui.py", line 84, in <module>
import resource_rc
ImportError: No module named resource_rc
This is the directory structure:
|-- my_application.pyw* (main application, "import resource.ui")
`-- resource/
|-- __init__.py (package file to enable module import)
|-- resource_rc.py (generated by pyrcc4)
`-- ui.py (generated by pyuic4, "import resource_rc")
I couldn't find any documentation regarding changes between the latest
Python 2 and 3. Who knows what's going on and what I can do?!
Thorsten
More information about the PyQt
mailing list