Not able to connect using secure=True
deepaknairrpf opened this issue · comments
Deepak commented
Getting the below exception when passing secure=True as follows:
conn = await connect(
host="<HOST>",
port=9440,
database="<DB>",
user="<USER>",
password="<PASSWORD>", secure=True
)
File "/home/deebug/PycharmProjects/pythonProject/asyncch_test.py", line 27, in <module>
asyncio.run(connect_database())
File "/home/deebug/miniconda3/lib/python3.7/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/home/deebug/miniconda3/lib/python3.7/asyncio/base_events.py", line 587, in run_until_complete
return future.result()
File "/home/deebug/PycharmProjects/pythonProject/asyncch_test.py", line 11, in connect_database
password="<PASSWORD>", secure=True
File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/connection.py", line 199, in connect
await conn.connect()
File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/connection.py", line 97, in connect
await self._connection.connect()
File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/connection.py", line 470, in connect
return await self._init_connection(host, port)
File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/connection.py", line 457, in _init_connection
await self.receive_hello()
File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/connection.py", line 199, in receive_hello
packet_type = await self.reader.read_varint()
File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/io.py", line 127, in read_varint
packet = self._read_one()
File "/home/deebug/PycharmProjects/pythonProject/venv3.7/lib/python3.7/site-packages/asynch/proto/io.py", line 117, in _read_one
packet = self.buffer[self.position]
IndexError: bytearray index out of range
Can you please provide a documentation or an example involving connecting using SSL?