#๐Ÿ”’ I cant compile my py file to exe

19 messages ยท Page 1 of 1 (latest)

safe badgerBOT
#

@vestal oriole

Python help channel opened

Remember to:

  • Ask your Python question, not if you can ask or if there's an expert who can help.
  • Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
  • Explain what you expect to happen and what actually happens.

:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.

vestal oriole
#

I cant compile my py file to exe.I need to compile it with pyqt5 and other libraries.I tried to do it based on Pyinstaller but exe file just opened and closed.Pls say me what i should to do or i can send u file and u will just compile it.PLS.U can write me on eng or rupy_strong

deft talon
#

Is your app window based or console based?

vestal oriole
#

window

deft talon
#

You need to set window-mode flag

vestal oriole
#

may be on russian?)

#

i setted

deft talon
#

send the command you enter to compile exe

vestal oriole
#

ok

#

pyinstaller kandinsky.spec

deft talon
#

use triple tildas `

#

not quotes

vestal oriole
#
# -*- mode: python ; coding: utf-8 -*-


a = Analysis(
    ['D:\\Progg\\kandinsky.py'],
    pathex=[],
    binaries=[],
    datas=[ (collect_data_files('PyQt5'), 'PyQt5')],
    hiddenimports=[],
    hookspath=[],
    hooksconfig={},
    runtime_hooks=[],
    excludes=[],
    noarchive=False,
    optimize=0,
)
pyz = PYZ(a.pure)

exe = EXE(
    pyz,
    a.scripts,
    a.binaries,
    a.datas,
    [],
    name='kandinsky',
    debug=False,
    bootloader_ignore_signals=False,
    strip=False,
    upx=True,
    upx_exclude=[],
    runtime_tmpdir=None,
    console=False,
    disable_windowed_traceback=False,
    argv_emulation=False,
    target_arch=None,
    codesign_identity=None,
    entitlements_file=None,
)
#

that is code what chatgpt writed for me

#

do you need main programm code?

vestal oriole
safe badgerBOT
#
Python help channel closed

This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.

#

๐Ÿ”’ I cant compile my py file to exe