Display a contantly updated text file in a web user interface using Python flask framework
The one way I can think of doing this is to refresh the page. So, you could set the page to refresh itself every X seconds.
You would hope that the file you are reading is not large though, or it will impact performance. Better to have the output in memory.
In my project workflow, i am invoking a sh script from a python script file. I am planning to introduce a web user interface for this, hence opted for flask framework. I am yet to figure out how to display the terminal output of the shell script invoked by my python script in a component like text area or label. This file is a log file which is constantly updated till the script run is completed. 
The solution i thought was to redirect terminal output to a text file and read the text file every X seconds and display the content. I can also do it via the Ajax way from my web application. Is there any other prescribed way to achieve this ?
Thanks