File “C:\Users\18660\PycharmProjects\dierbian\apps\users\views.py”, line 19, in post
if login_form.is_valid():
File “C:\Users\18660\Envs\mxonline\lib\site-packages\django\forms\forms.py”, line 185, in is_valid
return self.is_bound and not self.errors
File “C:\Users\18660\Envs\mxonline\lib\site-packages\django\forms\forms.py”, line 180, in errors
self.full_clean()
File “C:\Users\18660\Envs\mxonline\lib\site-packages\django\forms\forms.py”, line 382, in full_clean
self._clean_form()
File “C:\Users\18660\Envs\mxonline\lib\site-packages\django\forms\forms.py”, line 409, in _clean_form
cleaned_data = self.clean()
File “C:\Users\18660\PycharmProjects\dierbian\apps\users\forms.py”, line 33, in clean
code=self.cleaned_data[‘code’]
KeyError: ‘code’
[16/Jun/2020 03:10:49] “POST /d_login/ HTTP/1.1” 500 102479