Skip to content

AttributeError: 'NoneType' object has no attribute 'drivername' #1

Description

@ellierui

[root@wisdom-c flask-rest-api-master]# echo 'db.create_all()' | ./manage.py shell
/usr/lib64/python2.7/site-packages/flask_sqlalchemy/init.py:794: FSADeprecationWarning: SQLALCHEMY_TRACK_MODIFICATIONS adds significant overhead and will be disabled by default in the future. Set it to True or False to suppress this warning.
'SQLALCHEMY_TRACK_MODIFICATIONS adds significant overhead and '

Traceback (most recent call last):
File "", line 1, in
File "/usr/lib64/python2.7/site-packages/flask_sqlalchemy/init.py", line 963, in create_all
self._execute_for_all_tables(app, bind, 'create_all')
File "/usr/lib64/python2.7/site-packages/flask_sqlalchemy/init.py", line 955, in _execute_for_all_tables
op(bind=self.get_engine(app, bind), **extra)
File "/usr/lib64/python2.7/site-packages/flask_sqlalchemy/init.py", line 896, in get_engine
return connector.get_engine()
File "/usr/lib64/python2.7/site-packages/flask_sqlalchemy/init.py", line 556, in get_engine
self._sa.apply_driver_hacks(self._app, info, options)
File "/usr/lib64/python2.7/site-packages/flask_sqlalchemy/init.py", line 830, in apply_driver_hacks
if info.drivername.startswith('mysql'):
AttributeError: 'NoneType' object has no attribute 'drivername'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions