fbs-tutorial icon indicating copy to clipboard operation
fbs-tutorial copied to clipboard

fbs freeze failed

Open UmangRajpara13 opened this issue 4 years ago • 3 comments

"Ubuntu 20.04, python 3.6 in venv"

Traceback (most recent call last): File "/home/umang/Desktop/repos/Venv/bin/fbs", line 8, in sys.exit(_main()) File "/home/umang/Desktop/repos/Venv/lib/python3.6/site-packages/fbs/main.py", line 17, in _main fbs.cmdline.main() File "/home/umang/Desktop/repos/Venv/lib/python3.6/site-packages/fbs/cmdline.py", line 32, in main fn(*args) File "/home/umang/Desktop/repos/Venv/lib/python3.6/site-packages/fbs/builtin_commands/init.py", line 125, in freeze freeze_ubuntu(debug=debug) File "/home/umang/Desktop/repos/Venv/lib/python3.6/site-packages/fbs/freeze/ubuntu.py", line 4, in freeze_ubuntu freeze_linux(debug) File "/home/umang/Desktop/repos/Venv/lib/python3.6/site-packages/fbs/freeze/linux.py", line 8, in freeze_linux run_pyinstaller(debug=debug) File "/home/umang/Desktop/repos/Venv/lib/python3.6/site-packages/fbs/freeze/init.py", line 48, in run_pyinstaller run(args, check=True) File "/usr/lib/python3.6/subprocess.py", line 438, in run output=stdout, stderr=stderr) subprocess.CalledProcessError: Command '['pyinstaller', '--name', 'Awesome', '--noupx', '--log-level', 'ERROR', '--noconfirm', '--distpath', '/home/umang/Desktop/repos/Venv/target', '--specpath', '/home/umang/Desktop/repos/Venv/target/PyInstaller', '--workpath', '/home/umang/Desktop/repos/Venv/target/PyInstaller', '--additional-hooks-dir', '/home/umang/Desktop/repos/Venv/lib/python3.6/site-packages/fbs/freeze/hooks', '--runtime-hook', '/home/umang/Desktop/repos/Venv/target/PyInstaller/fbs_pyinstaller_hook.py', '/home/umang/Desktop/repos/Venv/src/main/python/main.py']' returned non-zero exit status 1.

UmangRajpara13 avatar Feb 15 '21 14:02 UmangRajpara13

[3012] Failed to execute script

is this error ,so please help me too

amarnathreddy0201 avatar Mar 24 '22 11:03 amarnathreddy0201

i dropped python for desktop application development. i moved to javascript and use electron framework.

UmangRajpara13 avatar Mar 24 '22 12:03 UmangRajpara13

try to add just this line in your python program: from fbs_runtime.application_context.PyQt5 import ApplicationContext

do NOT use this:

    appctxt = ApplicationContext()
    ....
    exit_code = appctxt.app.exec_()
    sys.exit(exit_code)

leave your main like it was -- like this:

def main():
    app = QtWidgets.QApplication(argv)
    t = Tetris()
    t.show()
    exit(app.exec_())

Ing-Josef-Klotzner avatar Aug 12 '22 22:08 Ing-Josef-Klotzner