sherlockwisdom / Afkanerd-Deku-Python-Port

Afkanerd-Deku-Daemon ported for python
3 stars 2 forks source link

Missing database config instructions in README.md #4

Closed nSedrickm closed 3 years ago

nSedrickm commented 3 years ago

Command run

python api.py

Resulting Error message

Traceback (most recent call last): File "api.py", line 13, in datastore = Datastore(configs_filepath="libs/config.ini") File "/home/nsedrickm/Documents/SMSwithoutborders/Afkanerd-Deku-Python-Port/src/ldatastore.py", line 22, in init self.conn = pymysql.connect( host=self.HOST, user=self.USER, password=self.PASSWORD, database=self.DATABASE, cursorclass=pymysql.cursors.SSDictCursor) File "/home/nsedrickm/Documents/SMSwithoutborders/Afkanerd-Deku-Python-Port/.venv/lib/python3.8/site-packages/pymysql/connections.py", line 353, in init self.connect() File "/home/nsedrickm/Documents/SMSwithoutborders/Afkanerd-Deku-Python-Port/.venv/lib/python3.8/site-packages/pymysql/connections.py", line 633, in connect self._request_authentication() File "/home/nsedrickm/Documents/SMSwithoutborders/Afkanerd-Deku-Python-Port/.venv/lib/python3.8/site-packages/pymysql/connections.py", line 907, in _request_authentication auth_packet = self._read_packet() File "/home/nsedrickm/Documents/SMSwithoutborders/Afkanerd-Deku-Python-Port/.venv/lib/python3.8/site-packages/pymysql/connections.py", line 725, in _read_packet packet.raise_for_error() File "/home/nsedrickm/Documents/SMSwithoutborders/Afkanerd-Deku-Python-Port/.venv/lib/python3.8/site-packages/pymysql/protocol.py", line 221, in raise_for_error err.raise_mysql_exception(self._data) File "/home/nsedrickm/Documents/SMSwithoutborders/Afkanerd-Deku-Python-Port/.venv/lib/python3.8/site-packages/pymysql/err.py", line 143, in raise_mysql_exception raise errorclass(errno, errval) pymysql.err.OperationalError: (1698, "Access denied for user 'root'@'localhost'")

sherlockwisdom commented 3 years ago

This is the configuration of your MySQL on your system - you probably do not have permission without sudo You should have the right user in the src/libs/config.ini file