Skip to content

Commit 313ffba

Browse files
committed
Add pymysql (fix the slalom around pymysql and mysqlclient)
1 parent b6d33e3 commit 313ffba

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

source/_components/recorder.markdown

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,16 +92,18 @@ If you only want to hide events from e.g. your history, take a look at the [`his
9292
| SQLite | `sqlite:///PATH/TO/DB_NAME` |
9393
| MySQL | `mysql://SERVER_IP/DB_NAME` |
9494
| MySQL           | `mysql://user:password@SERVER_IP/DB_NAME`       |
95+
| MySQL (pymysql) | `mysql+pymysql://SERVER_IP/DB_NAME` |
96+
| MySQL (pymysql) | `mysql+pymysql://user:password@SERVER_IP/DB_NAME` |
9597
| PostgreSQL | `postgresql://SERVER_IP/DB_NAME` |
9698
| PostgreSQL | `postgresql://scott:tiger@SERVER_IP/DB_NAME` |
9799

98100
## {% linkable_title Installation notes %}
99101

100102
Not all Python bindings for the chosen database engine can be installed directly. This section contains additional details which should help you to get it working.
101103

102-
### {% linkable_title MYSQL %}
104+
### {% linkable_title MySQL %}
103105

104-
For MySQL you may have to install a few dependencies:
106+
For MySQL you may have to install a few dependencies. You can choose between `pymysql` and `mysqlclient`:
105107

106108
```bash
107109
$ sudo apt-get install libmysqlclient-dev
@@ -111,7 +113,7 @@ If you are in a virtual environment, don't forget to activate it before installi
111113

112114
```bash
113115
pi@homeassistant:~ $ sudo -i
114-
root@homeassistant:~# su homeassistant
116+
root@homeassistant:~# su homeassistant
115117
homeassistant@homeassistant:/root$ cd /srv/homeassistant/homeassistant_venv/
116118
homeassistant@homeassistant:/srv/homeassistant/homeassistant_venv$ source bin/activate
117119
(homeassistant_venv) homeassistant@homeassistant:/srv/homeassistant/homeassistant_venv$ pip3 install mysqlclient

0 commit comments

Comments
 (0)