I am using python v2.7 and Requests HTTP library. I am using windows 7 OS.
I have failed to understand why the following code consumes more and more memory upon exec
I tested the code snippet for half an hour. I have finally concluded that the memory consumption increases in the beginning and later it gets in a state where it decreases as well as increases. Finally the memory consumption will remain in a range. I believe this is how the system is supposed to work after reading the useful comments. :)
I can only second some of the comments on your original post. I found http://www.digi.com/wiki/developer/index.php/Python_Garbage_Collection to be quite useful in case you want to gain better insight into the gc.