My Problem:
I have this problem where if I try to run py2exe on my python file that uses Pyqt/Pyside I get the following error when trying to run the EXE generated in I:\Documents\Python\Buttonio_Testio\dist :
Error recieved when running Package.exe:
I:\Documents\Python\Buttonio_Testio\dist>Package.exe
Traceback (most recent call last):
File "Package.py", line 1, in <module>
File "PySide\__init__.pyc", line 55, in <module>
File "PySide\__init__.pyc", line 11, in _setupQtDirectories
File "PySide\_utils.pyc", line 87, in get_pyside_dir
File "PySide\_utils.pyc", line 83, in _get_win32_case_sensitive_name
File "PySide\_utils.pyc", line 58, in _get_win32_short_name
WindowsError: [Error 3] The system cannot find the path specified.
My setup.py looks like this:
from distutils.core import setup
import py2exe
setup(console=['Package.py'])
My program, in Package.py looks like this:
from PySide.QtCore import *
from PySide.QtGui import *
import sys
import Gui
class Ui_Dialog(QDialog, Gui.Ui_Dialog):
#Setupui and function afterwards generated converting XML file made by QT Desiner to python.
def setupUi(self, Dialog):
Dialog.setObjectName("Dialog")
Dialog.resize(279, 295)
self.textBrowser = QtGui.QTextBrowser(Dialog)
self.textBrowser.setGeometry(QtCore.QRect(10, 10, 256, 192))
self.textBrowser.setObjectName("textBrowser")
self.pushButton = QtGui.QPushButton(Dialog)
self.pushButton.setGeometry(QtCore.QRect(10, 210, 251, 71))
self.pushButton.setObjectName("PushButton")
self.retranslateUi(Dialog)
QtCore.QObject.connect(self.pushButton, QtCore.SIGNAL("clicked()"), self.textBrowser.clear)
QtCore.QMetaObject.connectSlotsByName(Dialog)
def retranslateUi(self, Dialog):
Dialog.setWindowTitle(QtGui.QApplication.translate("Dialog", "Dialog", None, QtGui.QApplication.UnicodeUTF8))
self.pushButton.setText(QtGui.QApplication.translate("Dialog", "Clear Spam", None, QtGui.QApplication.UnicodeUTF8))
def __init__(self, parent=None):
super(Ui_Dialog, self).__init__(parent)
self.setupUi(self)
self.spam()
def spam(self):
self.textBrowser.append("SPAM")
self.textBrowser.append("SPAM")
self.textBrowser.append("SPAM")
self.textBrowser.append("LOL")
self.textBrowser.append("I")
self.textBrowser.append("AM")
self.textBrowser.append("SPAMMING")
self.textBrowser.append("MYSELF")
app = QApplication(sys.argv)
form = Ui_Dialog()
form.show()
app.exec_()
I am running windows 8 with 32bit python and 32bit modules installed. The setup.py file was in the same folder as Package.py when I ran setup.py in Command Prompt. Besides that I don't know what other information may help fix my problem.
That's all, thank you for any answers in advance.