You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What is the best way to enforce constant flushing in python-3 if I have console=False in my Pyinstaller spec file? In particular, I am using the progress bar package tqdm and wanted to have the real-time progress displayed during the computation.
I saw an older post that points out the fact that -u flag never makes it to the interpreter and suggests to do:
But here the trouble is that with console=False (in my spec file), sys.stdout becomes a NullWriter and sys.__stdout__ becomes None, and so I can't for example call .fileno() method. I've also tried just setting PYTHONUNBUFFERED environmental variable to a non-empty string, but it doesn't affect anything since -u doesn't make it to the interpreter.
[Windows-10] OS
[3.9.2] Python Version
[1.0.8] Gooey Version
[4.8.1] Pyinstaller
thank you for your time!
The text was updated successfully, but these errors were encountered:
Unfortunately, I'm not totally sure what the best practice is these days for PyInstaller + the specific Python / OS versions. I'd suggest opening a ticket against the PyInstaller peeps for guidance. It seems to be a constantly evolving art : (
Closing this in favor of the Big List of PyInstaller Issues here. Feel free to comment there. People have had good luck working through the issues in that thread.
thanks for creating this awesome tool!
What is the best way to enforce constant flushing in python-3 if I have
console=False
in my Pyinstaller spec file? In particular, I am using the progress bar package tqdm and wanted to have the real-time progress displayed during the computation.I saw an older post that points out the fact that
-u
flag never makes it to the interpreter and suggests to do:which perhaps should be handled in python-3 as (?):
But here the trouble is that with
console=False
(in my spec file),sys.stdout
becomes aNullWriter
andsys.__stdout__
becomesNone
, and so I can't for example call.fileno()
method. I've also tried just settingPYTHONUNBUFFERED
environmental variable to a non-empty string, but it doesn't affect anything since -u doesn't make it to the interpreter.thank you for your time!
The text was updated successfully, but these errors were encountered: