After a electrical failure my network database having problems
I open my login page by running the program but after, the username and password are no longer recognized
I get the error
Exception Type: DatabaseError
Value Exception: database is locked
and my function :
def main_page(request):
state = ""
username = password = ''
if request.POST:
username = request.POST.get('username')
password = request.POST.get('password')
user = authenticate(username=username, password=password)
The problem comes from this line : user =....
How can I fix this ?