def METHOD_NAME():
    async def main():
        result = []
        async def purge(items, attributes):
            result.append(dict(items))
        async with PoolManager("test", 3,
                               on_pool_purge=purge,
                               pass_pool_as_dict=True,
                               replace_item_on_append=False
                               ) as m:
            await m.append(1, key="a")
            await m.append(2, key="b")
            await m.append(3, key="b")
            await m.append(4, key="a")
            await m.append(5)
            await m.append(5)
        await asyncio.sleep(1)
        return result
    result = asyncio.run(main())
    assert result == [{'a': [1], 'b': [2, 3]}, {'a': [4], 'test': [5, 5]}]