I'm not sure why I can't import the db_password
variable.
Running db_setup gives:
Traceback (most recent call last):
File "db_setup.py", line 5, in <module>
passwd=dbconfig.db_password)
TypeError: 'module' object is not callable
I'm missing something but i'm not sure what.
I can open up an interperter and import dbconfig
as well as call `dbconfig.db_password'
db_setup.py
import pymysql
import dbconfig
connection = pymysql.connections(host='localhost', user=dbconfig.db_user, passwd=dbconfig.db_password)
dbconfig.py
db_user='username'
db_password='password'
I expect the module to pass the variable 'password'