Closed
Description
Long story short
I'm working on a long running program that makes a significant number of https requests, and the memory of the program increases steadily.
Expected behaviour
I would expect the memory to remain relatively constant.
Actual behaviour
For a sample 500 requests the memory increases approximate 8 meg doing just requests.
Steps to reproduce
import logging
import asyncio
import aiohttp
import gc
async def get():
response = await aiohttp.request('get', 'https://ddunlop.com')
logging.info(response.status)
response.close()
async def main(loop):
await asyncio.sleep(10)
for x in range(0, 500):
await get()
logging.info('done fetching')
gc.collect()
await asyncio.sleep(60)
if __name__ == '__main__':
logging.getLogger().setLevel('DEBUG')
loop = asyncio.get_event_loop()
loop.run_until_complete(main(loop))Your environment
aiohttp 2.0.2 inside a python:3.6.0-slim docker container.