I am using sqlite database and I declared the models as in this gist
https://gist.github.com/mmahesh/7245561
I have added a model instance with transaction manager as
with transaction.manager:
model = Users(username='example',name='Example', email_primary='m@m.com', _password='example')
DBSession.add(model)
Whenever I execute initialize_sample_db development.ini, this error shows up
sqlalchemy.exc.IntegrityError: (IntegrityError) constraint failed 'INSERT INTO users (name, username, email_primary, email_secondary, _password, bio) VALUES (?, ?, ?, ?, ?, ?)' ('Example', 'example', 'm@m.com', None, 'example', None )
Additional Information: when i use sqlite3 command tool and after '.d' command i get
PRAGMA foreign_keys=OFF;
BEGIN TRANSACTION;
COMMIT;
Thanks in advance