Skip to content Skip to sidebar Skip to footer

Python --> Pyinstaller - .exe File Will Return "test Returned -1"

[1] The code is: import Tkinter from Tkinter import * # Create Tk instance root = Tkinter.Tk(className='test') # Open Notepad def openNotepad(): import pywinauto app = p

Solution 1:

By commenting out the line starting with: excludedimports in files \PyInstaller\hooks\hook-PIL.py and hook-PIL.SpiderImagePlugin.py, the problem was solved.

Solution 2:

Try to replace every exit(), quit(), or os._exit() with sys.exit(). I see that you don't have any of these in your code but somebody else might find this advice to be useful.

My versions: python3.4, pyinstaller3.1.1

Post a Comment for "Python --> Pyinstaller - .exe File Will Return "test Returned -1""