Forward stdout to some widget
See original GitHub issueProblem
I tried to use streamlit for the interactive clustering app.
In my case clustering is long. And the only way to see any progress is to use verbose=1
. In such a case, sklearn algorithm put some information to stdout.
But I see no possibility to show this information with streamlit.
Community voting on feature requests enables the Streamlit team to understand which features are most important to our users.
If you’d like the Streamlit team to prioritize this feature request, please use the 👍 (thumbs up emoji) reaction in response to the initial post.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:8
- Comments:15 (4 by maintainers)
Top Results From Across the Web
How to redirect stdout to a Tkinter Text widget - Stack Overflow
Inorder to help ya'll if you struggling with this, I've made a script to redirect stdout to a Tkinter Text widget, see it...
Read more >Tkinter - Redirecting stdout / stderr - Mouse Vs Python
The first class we see is called RedirectText. It takes a text control widget as its parameter. we create a write method that...
Read more >redirect stdout to tkinter text widget : r/learnpython - Reddit
Hi, I have created a tool for web automation with selenium and have build a GUI with tkinter. The program works fine, but...
Read more >Re: redirecting stdout to gtk_text widget - GNOME Mail Services
I need help on how to redirect stdout to a text widget. ... Creates a new text view with a text buffer "Hello,...
Read more >Thread: [question]redirecting stdout to display via widget?
I'm very new to PyQt4 (its my fifth day) and I would like some help with this ... I would like to redirect...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I created a gist from this problem https://gist.github.com/schaumb/037f139035d93cff3ad9f4f7e5f739ce with a simplified syntax, and with realtime output:
It can be configure easily:
It can be nesting:
What do you think?
I built on zblz’s workaround and turned it into a wrapper that might be useful for some people:
Then you can do something like
which makes print debugging easier
edit: added relevant import statements for code snippet