>But Flask does not give control of what happens when the client suddenly closes the connection.
It is so annoying that they don't give you a way to do this. I built an LLM inference API but am still working on how to cancel an inference job if a client cancels. I really don't want to rewrite my entire server in Twisted so I'll probably end up just building the HTTP responses like you did.
I have a theory as to why pedestrian deaths have risen significantly above pre-pandemic levels, and it might be related to a side effect of COVID-19 known as "brain fog."
Many people who have recovered from COVID-19 have reported experiencing cognitive issues, such as difficulty concentrating, memory problems, and mental fatigue. This condition, often referred to as "brain fog," can persist for weeks or even months after the initial infection.
My hypothesis is that this brain fog may be impacting pedestrians' and driver's ability to stay alert and make quick, safe decisions while navigating streets and crosswalks. If a substantial portion of the population is experiencing these cognitive challenges, it could lead to more accidents involving pedestrians.