How can I detect and verify a memory leak in Flask's request context caused by uncleaned g data?
I want to determine whether storing large temporary objects in the Flask `g` proxy for each request leads to a memory leak, and how to confirm that a fix using `teardown_appcontext` actually releases those objects. The goal is to observe memory growth over many requests and ensure it stabilizes after the cleanup. I am working with a standard Flask applicatio