Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pyinstaller --noconsole issue #105

Closed
jcytam opened this issue Dec 5, 2022 · 9 comments
Closed

Pyinstaller --noconsole issue #105

jcytam opened this issue Dec 5, 2022 · 9 comments

Comments

@jcytam
Copy link

jcytam commented Dec 5, 2022

Thanks for all your work with this package. I changed over to the 1.x updates, and tried to use pyinstaller to package into an executable. Works just fine in --console mode, but the server appears to fail to start if --noconsole is called with pyinstaller to suppress the console. A chrome window pops up nonetheless but no web app on the address. Don't have a way to look for errors since the console is suppressed as well! Wondered if you've ran into this problem before.

@ClimenteA
Copy link
Owner

I'll look into it. If you are using windows checkout my pyvan repo see if that works out for you.

@CosmoFox
Copy link

Got same problem

@jcytam
Copy link
Author

jcytam commented Dec 12, 2022

I rolled back to flaskwebgui 0.3.7 and interestingly the problem persists. I wonder if it may be something to do with the pyinstaller update on 4/12... I'll try rolling back pyinstaller and report back.

I tried pyvan which worked well, but unfortunately presented its own problems which I will put in issues on that repo!

@ClimenteA
Copy link
Owner

Yeah... packaging a python desktop app is a pain...

@crushr3sist
Copy link

Wait I don't get what the issue is. The --noconsole flag can easily be avoided by building your apps with

pyinstaller -w -F --add-data "templates;templates" --add-data "static;static" main.py

if it's development in which this error occurs, then you should just be using flask to serve the HTML. You should also increase your idle interval and set close_server_on_exit to true as well.

@jcytam
Copy link
Author

jcytam commented Jan 10, 2023

I rolled back pyinstaller to 5.6.2 and the issue resolved. So I suspect this is a problem with pysintaller 5.7.0 rather than flaskwebgui.

-w is simply the short form of --noconsole, so running @Wizock's suggestion did not make a difference.

@jcytam jcytam closed this as completed Jan 10, 2023
@ClimenteA
Copy link
Owner

Thank you for updating this issue.

@Nriver
Copy link

Nriver commented Feb 22, 2023

As a temporary fix, I find this python-eel/Eel#654 works.

@ClimenteA
Copy link
Owner

Nice, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants