Every time I use a while loop, it seems Streamlit gets stuck inside it. Even if I tell the loop to break as soon as a certain condition is True, the condition remains the same. I also have tried putting the while loop inside a function and call it using a thread (foreground and background) and the result was the same.
Is there any workaround for this? Loops are one of the most used logics in programming languages.