Description
Describe the bug
We are trying to create the connection pool using trio, we get the below error
error
File "/home/serveradmin/bin/zoowie/app_server/db_connection.py", line 8, in db_connection
async with db_pool.connection() as conn:
File "/usr/local/lib/python3.6/dist-packages/rethinkdb/trio_net/net_trio.py", line 462, in aenter
self._conn = await self._pool.acquire()
File "/usr/local/lib/python3.6/dist-packages/rethinkdb/trio_net/net_trio.py", line 502, in acquire
conn = await make_connection(*self._args, **self._kwargs)
TypeError: make_connection() missing 1 required positional argument: 'connection_type'
code
async def db_connection():
r.set_loop_type('trio')
async with trio.open_nursery() as nursery:
db_pool = r.ConnectionPool(db='zoowie', nursery=nursery)
async with db_pool.connection() as conn:
print("Hello")
allUsers = await r.table('zo_country').order_by("name").limit(10).run(conn)
print('Users', allUsers)
await db_pool.close()