Django: Fix "OperationalError: database is locked" error

0 Comments

If you're using the shell to do some testing, this error could cause you some grief and set you back by forcing you to start the terminal.

Thankfully, the solution is short.

Just paste in this snippet and it'll be rolled back to a usable state.

1.from django.db import transaction
2.transaction.rollback()

Sources

 
Copyright © Twig's Tech Tips
Theme by BloggerThemes & TopWPThemes Sponsored by iBlogtoBlog