cx_freeze problem
Verfasst: Samstag 22. November 2014, 11:26
Ich habe mir gerade eben cx_freeze installiert eine Datei namens setup.py gemacht in der folgendes drinnensteht:
in Main.py steht
und wenn ich das dann in der cmd compiliere mit setup.py build dann wird es compiliert aber wenn ich dann Main.exe ausführe kommt:
C:\Users\*\Desktop\Vokabelkasten\build\exe.win32-3.4>Main.exe
Traceback (most recent call last):
File "C:\Python34\lib\site-packages\cx_Freeze\initscripts\Console.py", line 27
, in <module>
exec(code, m.__dict__)
File "Main.py", line 1, in <module>
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 2214, in _find_a
nd_load
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 2203, in _find_a
nd_load_unlocked
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 1191, in _load_u
nlocked
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 1161, in _load_b
ackward_compatible
AttributeError: 'module' object has no attribute '_fix_up_module'
C:\Users\*\Desktop\Vokabelkasten\build\exe.win32-3.4>
Und ich muss es irgendwie in .exe umwandeln kann mir jemand helfen?
Code: Alles auswählen
from cx_Freeze import setup, Executable
setup(
executables = [Executable("Main.py")])
Code: Alles auswählen
from UI import *
def enter(msg,default):
global pressd
root = Tk()
l = Label(root,text = msg)
T = Text(root, height=1, width=30)
button = Button(root, text='Ok', width=25, command=root.destroy)
l.pack(fill = X)
T.pack(fill = X)
button.pack(fill = X)
T.insert(END, default)
mainloop()
return "Text"
C:\Users\*\Desktop\Vokabelkasten\build\exe.win32-3.4>Main.exe
Traceback (most recent call last):
File "C:\Python34\lib\site-packages\cx_Freeze\initscripts\Console.py", line 27
, in <module>
exec(code, m.__dict__)
File "Main.py", line 1, in <module>
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 2214, in _find_a
nd_load
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 2203, in _find_a
nd_load_unlocked
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 1191, in _load_u
nlocked
File "c:\python\32-bit\3.4\lib\importlib\_bootstrap.py", line 1161, in _load_b
ackward_compatible
AttributeError: 'module' object has no attribute '_fix_up_module'
C:\Users\*\Desktop\Vokabelkasten\build\exe.win32-3.4>
Und ich muss es irgendwie in .exe umwandeln kann mir jemand helfen?