prprprus / PyMySQLPool

PyMySQL-based database connection pool.
MIT License
60 stars 21 forks source link

ping_check is not working #23

Open Greetlist opened 1 year ago

Greetlist commented 1 year ago

What happened

ping_check is not working, no matter I set it to int or bool

Env

  1. Ubuntu 20.04
  2. Miniconda 23.1.0
  3. Base Env: python3.8

How I fix it temporarily

https://github.com/prprprus/PyMySQLPool/blob/212110afaaa01f1d0d3faa8fe099ad19f48a8fbe/pymysqlpool/pool.py#L179

change __ping_check_timestamp ==> _Pool__ping_check_timestamp

Discussion

I do not know why origin code is not working, I also think it it right at first. Maybe it related to Miniconda or Python version?