-
-
Notifications
You must be signed in to change notification settings - Fork 591
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
--noconsole not working #654
Comments
Same here, trying to find a solution or workaround, but no lucky until now... let me know if you find something, please |
@francescofact @lucasadsouza We faced same problem on project. This soulution is not maybe for everyone but as a workaround will help you. Attempt to redirect Version:
|
Thank you. I also figure out a similar temporary solution.
|
@francescofact @snopedom @lucasadsouza Here's another solution that I used for a project a couple years back. It's working as of November 2022.
|
it's work for me. just need to write this code snippet before |
Hello, This is odd because I am using a chrome-app binary created with --noconsole --onefile. Works fine for chrome but not edge which I fixed here: #626 Thanks
|
I ran into this issue as well and it might be a bottle issue since the screenshot shows from file bottle.py line 73, which shows this: 72: try:
73: _stdout, _stderr = sys.stdout.write, sys.stderr.write
74: except IOError:
75: _stdout = lambda x: sys.stdout.write(x)
76: _stderr = lambda x: sys.stderr.write(x) using --noconsole causes an AttributeError (probably because the console does not exist so there is nothing to write to) I sort of did this in my bottle files before running pyinstaller, which may not be the best solution but was a temp fix that worked for me: 72: try:
73: _stdout, _stderr = sys.stdout.write, sys.stderr.write
74: except IOError:
75: _stdout = lambda x: sys.stdout.write(x)
76: _stderr = lambda x: sys.stderr.write(x)
77: except AttributeError:
78: pass Not sure what can really be done for it |
The correct fix is just to check that if sys.stderr:
sys.stderr.write("...") This is in both Python and PyInstaller's documentation. |
Hello, I've built an app with eel and now I'm trying to make an executable from it. But if I try to disable the console it doesn't start and shows the following error:
I'm using this command:
python -m eel app.py web --onefile --noconsole --splash splash.png
and from python I just run
eel.start('index.html')
I tried to redirect sys.stderr and sys.stdout to a StringIO or a PIPE but still the error popup.
I'm on windows and the app runs with Chrome.
The text was updated successfully, but these errors were encountered: