connector-x
connector-x copied to clipboard
Cannot terminate using Ctrl+C/D
What language are you using?
python
What version are you using?
0.3.1
What database are you using?
PostgreSQL
What dataframe are you using?
polars
Can you describe your bug?
Give a high level description of the bug.
What are the steps to reproduce the behavior?
If possible, please include a minimal simple example including:
Database setup if the error only happens on specific data or data type
Table schema and example data
Example query / code
import connectorx as cx
sql = """
select 1;
"""
db1 = "postgresql://xxchan:@127.0.0.1:11451/postgres"
data = cx.read_sql(db1, query=sql, return_type="polars")
What is the error?
Show the error result here.
> python test.py
[2023-02-16T13:21:21Z ERROR r2d2] error connecting to server: Connection refused (os error 61)
[2023-02-16T13:21:22Z ERROR r2d2] error connecting to server: Connection refused (os error 61)
[2023-02-16T13:21:23Z ERROR r2d2] error connecting to server: Connection refused (os error 61)
^C^C^C[2023-02-16T13:21:24Z ERROR r2d2] error connecting to server: Connection refused (os error 61)
^C^C^C^C[2023-02-16T13:21:27Z ERROR r2d2] error connecting to server: Connection refused (os error 61)
^D
I expect the program can exit immediately
Same problem here.
But using CTRL + Z I could stop it.
user@MY-PC:~/polars_test$ python3 is450.py
[2023-03-09T23:16:31Z ERROR r2d2] error connecting to server: Connection refused (os error 111)
[2023-03-09T23:16:32Z ERROR r2d2] error connecting to server: Connection refused (os error 111)
[2023-03-09T23:16:32Z ERROR r2d2] error connecting to server: Connection refused (os error 111)
^Z
[2]+ Stopped python3 is450.py
user@MY-PC:~/polars_test$