Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-19 Thread Leo guitar girl
I have sent you an invitation

On Wed, Jan 19, 2022 at 9:54 AM Vkash Poudel 
wrote:

> can we connect via email so that i can share my codes regarding Time basis
> OTP Generation and OTP Verification and activate user's account using pyotp.
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> On Wed, Jan 19, 2022 at 1:20 AM Leo guitar girl <
> mansarimtabas...@gmail.com> wrote:
>
>> I have not used any library. I have done manual OTP verification by using
>> Rand library as told in the tutorial.
>>
>> On Tue, Jan 18, 2022 at 9:00 PM Vkash Poudel 
>> wrote:
>>
>>> first of what did you use to generate otp. If you've used pyotp
>>> libraries then you can verify otp in simple step and the documentation is
>>> good in pyotp.
>>>
>>> On Tue, Jan 18, 2022 at 8:35 PM Leo guitar girl <
>>> mansarimtabas...@gmail.com> wrote:
>>>
 I am following the tutorial from LearnVern.com


 https://www.learnvern.com/python-tutorial-django/project-implementation-part2

 I have followed ditto as taught in the tutorial but the trainer has no
 issue and I have this issue.

 I am sharing the views.py code also

 from django.shortcuts import render
 from .models import *
 from random import randint


 # Create your views here.

 def Index(request):
 return render(request, 'myapp/index.html')


 def SignupPage(request):
 return render(request, 'myapp/signup.html')


 def RegisterUser(request):
 if request.POST['role'] == "Candidate":
 role = request.POST['role']  # Master Table Field
 fname = request.POST['fname']  # Candidate Table Field
 lname = request.POST['lname']  # Candidate Table Field
 email = request.POST['email']  # Master Table Field
 password = request.POST['password']  # Master Table Field
 cpassword = request.POST['cpassword']

 user = UserMaster.objects.filter(email=email)

 if user:
 message = "User already Exist"
 return render(request, "myapp/signup.html", {'msg': message})
 else:
 if password == cpassword:
 otp = randint(10, 99)
 newuser = UserMaster.objects.create(role=role, otp=otp, 
 email=email, password=password)
 newcand = Candidate.objects.create(user_id=newuser, 
 firstname=fname, lastname=lname)
 return render(request, "myapp/otpverify.html", {'email': 
 email})
 else:
 print("Company Registration")


 def OTPpage(request):
 return render(request, "myapp/otpverify.html")


 def OTPverify(request):
 if request.method == 'POST':
 email = request.POST['email']
 otp = request.POST['otp']

 user = UserMaster.objects.get(email=email)

 if user:
 if user.otp == otp:
 message = "OTP Verified Successfully!"
 return render(request, "myapp/login.html", {'msg': 
 message})
 else:
 message = "OTP is incorrect"
 return render(request, "myapp/otpverify.html", {'msg': 
 message})
 else:
 return render(request, "myapp/signup.html")


 On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
 wrote:

> On 18/01/2022 04.31, Leo guitar girl wrote:
> > Oh, I apologize. I had pasted the error code here don't know why it
> was
> > not sent.
> > Actually, I am trying to create a job portal by seeing a tutorial.
> Now I
> > am at the step of verifying OTP. OTP is generated successfully in
> the
> > database. But when I enter it to the textbox and submit, it shows
> this error
> >
>
> Which tutorial are you following?
>
> What's in the views.py file that is causing the error?
>
> Kind regards,
>
> Kasper Laudrup
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe
> .
> To unsubscribe from this group and all it

Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-19 Thread Leo guitar girl
yeah sure

On Wed, Jan 19, 2022 at 9:54 AM Vkash Poudel 
wrote:

> can we connect via email so that i can share my codes regarding Time basis
> OTP Generation and OTP Verification and activate user's account using pyotp.
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> On Wed, Jan 19, 2022 at 1:20 AM Leo guitar girl <
> mansarimtabas...@gmail.com> wrote:
>
>> I have not used any library. I have done manual OTP verification by using
>> Rand library as told in the tutorial.
>>
>> On Tue, Jan 18, 2022 at 9:00 PM Vkash Poudel 
>> wrote:
>>
>>> first of what did you use to generate otp. If you've used pyotp
>>> libraries then you can verify otp in simple step and the documentation is
>>> good in pyotp.
>>>
>>> On Tue, Jan 18, 2022 at 8:35 PM Leo guitar girl <
>>> mansarimtabas...@gmail.com> wrote:
>>>
 I am following the tutorial from LearnVern.com


 https://www.learnvern.com/python-tutorial-django/project-implementation-part2

 I have followed ditto as taught in the tutorial but the trainer has no
 issue and I have this issue.

 I am sharing the views.py code also

 from django.shortcuts import render
 from .models import *
 from random import randint


 # Create your views here.

 def Index(request):
 return render(request, 'myapp/index.html')


 def SignupPage(request):
 return render(request, 'myapp/signup.html')


 def RegisterUser(request):
 if request.POST['role'] == "Candidate":
 role = request.POST['role']  # Master Table Field
 fname = request.POST['fname']  # Candidate Table Field
 lname = request.POST['lname']  # Candidate Table Field
 email = request.POST['email']  # Master Table Field
 password = request.POST['password']  # Master Table Field
 cpassword = request.POST['cpassword']

 user = UserMaster.objects.filter(email=email)

 if user:
 message = "User already Exist"
 return render(request, "myapp/signup.html", {'msg': message})
 else:
 if password == cpassword:
 otp = randint(10, 99)
 newuser = UserMaster.objects.create(role=role, otp=otp, 
 email=email, password=password)
 newcand = Candidate.objects.create(user_id=newuser, 
 firstname=fname, lastname=lname)
 return render(request, "myapp/otpverify.html", {'email': 
 email})
 else:
 print("Company Registration")


 def OTPpage(request):
 return render(request, "myapp/otpverify.html")


 def OTPverify(request):
 if request.method == 'POST':
 email = request.POST['email']
 otp = request.POST['otp']

 user = UserMaster.objects.get(email=email)

 if user:
 if user.otp == otp:
 message = "OTP Verified Successfully!"
 return render(request, "myapp/login.html", {'msg': 
 message})
 else:
 message = "OTP is incorrect"
 return render(request, "myapp/otpverify.html", {'msg': 
 message})
 else:
 return render(request, "myapp/signup.html")


 On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
 wrote:

> On 18/01/2022 04.31, Leo guitar girl wrote:
> > Oh, I apologize. I had pasted the error code here don't know why it
> was
> > not sent.
> > Actually, I am trying to create a job portal by seeing a tutorial.
> Now I
> > am at the step of verifying OTP. OTP is generated successfully in
> the
> > database. But when I enter it to the textbox and submit, it shows
> this error
> >
>
> Which tutorial are you following?
>
> What's in the views.py file that is causing the error?
>
> Kind regards,
>
> Kasper Laudrup
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an em

Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Vkash Poudel
can we connect via email so that i can share my codes regarding Time basis
OTP Generation and OTP Verification and activate user's account using pyotp.






































































































































































































































































































































On Wed, Jan 19, 2022 at 1:20 AM Leo guitar girl 
wrote:

> I have not used any library. I have done manual OTP verification by using
> Rand library as told in the tutorial.
>
> On Tue, Jan 18, 2022 at 9:00 PM Vkash Poudel 
> wrote:
>
>> first of what did you use to generate otp. If you've used pyotp libraries
>> then you can verify otp in simple step and the documentation is good in
>> pyotp.
>>
>> On Tue, Jan 18, 2022 at 8:35 PM Leo guitar girl <
>> mansarimtabas...@gmail.com> wrote:
>>
>>> I am following the tutorial from LearnVern.com
>>>
>>>
>>> https://www.learnvern.com/python-tutorial-django/project-implementation-part2
>>>
>>> I have followed ditto as taught in the tutorial but the trainer has no
>>> issue and I have this issue.
>>>
>>> I am sharing the views.py code also
>>>
>>> from django.shortcuts import render
>>> from .models import *
>>> from random import randint
>>>
>>>
>>> # Create your views here.
>>>
>>> def Index(request):
>>> return render(request, 'myapp/index.html')
>>>
>>>
>>> def SignupPage(request):
>>> return render(request, 'myapp/signup.html')
>>>
>>>
>>> def RegisterUser(request):
>>> if request.POST['role'] == "Candidate":
>>> role = request.POST['role']  # Master Table Field
>>> fname = request.POST['fname']  # Candidate Table Field
>>> lname = request.POST['lname']  # Candidate Table Field
>>> email = request.POST['email']  # Master Table Field
>>> password = request.POST['password']  # Master Table Field
>>> cpassword = request.POST['cpassword']
>>>
>>> user = UserMaster.objects.filter(email=email)
>>>
>>> if user:
>>> message = "User already Exist"
>>> return render(request, "myapp/signup.html", {'msg': message})
>>> else:
>>> if password == cpassword:
>>> otp = randint(10, 99)
>>> newuser = UserMaster.objects.create(role=role, otp=otp, 
>>> email=email, password=password)
>>> newcand = Candidate.objects.create(user_id=newuser, 
>>> firstname=fname, lastname=lname)
>>> return render(request, "myapp/otpverify.html", {'email': 
>>> email})
>>> else:
>>> print("Company Registration")
>>>
>>>
>>> def OTPpage(request):
>>> return render(request, "myapp/otpverify.html")
>>>
>>>
>>> def OTPverify(request):
>>> if request.method == 'POST':
>>> email = request.POST['email']
>>> otp = request.POST['otp']
>>>
>>> user = UserMaster.objects.get(email=email)
>>>
>>> if user:
>>> if user.otp == otp:
>>> message = "OTP Verified Successfully!"
>>> return render(request, "myapp/login.html", {'msg': message})
>>> else:
>>> message = "OTP is incorrect"
>>> return render(request, "myapp/otpverify.html", {'msg': 
>>> message})
>>> else:
>>> return render(request, "myapp/signup.html")
>>>
>>>
>>> On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
>>> wrote:
>>>
 On 18/01/2022 04.31, Leo guitar girl wrote:
 > Oh, I apologize. I had pasted the error code here don't know why it
 was
 > not sent.
 > Actually, I am trying to create a job portal by seeing a tutorial.
 Now I
 > am at the step of verifying OTP. OTP is generated successfully in the
 > database. But when I enter it to the textbox and submit, it shows
 this error
 >

 Which tutorial are you following?

 What's in the views.py file that is causing the error?

 Kind regards,

 Kasper Laudrup

 --
 You received this message because you are subscribed to a topic in the
 Google Groups "Django users" group.
 To unsubscribe from this topic, visit
 https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
 To unsubscribe from this group and all its topics, send an email to
 django-users+unsubscr...@googlegroups.com.
 To view this discussion on the web visit
 https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk
 .

>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to django-users+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CAN6g

Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Leo guitar girl
I have not used any library. I have done manual OTP verification by using
Rand library as told in the tutorial.

On Tue, Jan 18, 2022 at 9:00 PM Vkash Poudel 
wrote:

> first of what did you use to generate otp. If you've used pyotp libraries
> then you can verify otp in simple step and the documentation is good in
> pyotp.
>
> On Tue, Jan 18, 2022 at 8:35 PM Leo guitar girl <
> mansarimtabas...@gmail.com> wrote:
>
>> I am following the tutorial from LearnVern.com
>>
>>
>> https://www.learnvern.com/python-tutorial-django/project-implementation-part2
>>
>> I have followed ditto as taught in the tutorial but the trainer has no
>> issue and I have this issue.
>>
>> I am sharing the views.py code also
>>
>> from django.shortcuts import render
>> from .models import *
>> from random import randint
>>
>>
>> # Create your views here.
>>
>> def Index(request):
>> return render(request, 'myapp/index.html')
>>
>>
>> def SignupPage(request):
>> return render(request, 'myapp/signup.html')
>>
>>
>> def RegisterUser(request):
>> if request.POST['role'] == "Candidate":
>> role = request.POST['role']  # Master Table Field
>> fname = request.POST['fname']  # Candidate Table Field
>> lname = request.POST['lname']  # Candidate Table Field
>> email = request.POST['email']  # Master Table Field
>> password = request.POST['password']  # Master Table Field
>> cpassword = request.POST['cpassword']
>>
>> user = UserMaster.objects.filter(email=email)
>>
>> if user:
>> message = "User already Exist"
>> return render(request, "myapp/signup.html", {'msg': message})
>> else:
>> if password == cpassword:
>> otp = randint(10, 99)
>> newuser = UserMaster.objects.create(role=role, otp=otp, 
>> email=email, password=password)
>> newcand = Candidate.objects.create(user_id=newuser, 
>> firstname=fname, lastname=lname)
>> return render(request, "myapp/otpverify.html", {'email': 
>> email})
>> else:
>> print("Company Registration")
>>
>>
>> def OTPpage(request):
>> return render(request, "myapp/otpverify.html")
>>
>>
>> def OTPverify(request):
>> if request.method == 'POST':
>> email = request.POST['email']
>> otp = request.POST['otp']
>>
>> user = UserMaster.objects.get(email=email)
>>
>> if user:
>> if user.otp == otp:
>> message = "OTP Verified Successfully!"
>> return render(request, "myapp/login.html", {'msg': message})
>> else:
>> message = "OTP is incorrect"
>> return render(request, "myapp/otpverify.html", {'msg': 
>> message})
>> else:
>> return render(request, "myapp/signup.html")
>>
>>
>> On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
>> wrote:
>>
>>> On 18/01/2022 04.31, Leo guitar girl wrote:
>>> > Oh, I apologize. I had pasted the error code here don't know why it
>>> was
>>> > not sent.
>>> > Actually, I am trying to create a job portal by seeing a tutorial. Now
>>> I
>>> > am at the step of verifying OTP. OTP is generated successfully in the
>>> > database. But when I enter it to the textbox and submit, it shows
>>> this error
>>> >
>>>
>>> Which tutorial are you following?
>>>
>>> What's in the views.py file that is causing the error?
>>>
>>> Kind regards,
>>>
>>> Kasper Laudrup
>>>
>>> --
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "Django users" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to
>>> django-users+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk
>>> .
>>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CAN6g9JZG-4VbKFDOJtWg3rMWY4i23Gh%2Bga3PfKxYBmVMR38ayw%40mail.gmail.com
>> 
>> .
>>
>
>
> --
> Best Regards,
> Bikash Poudel
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> ht

Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Leo guitar girl
I have changed the code as you suggested.

def OTPverify(request):
if request.method == 'POST':
email = request.POST.*get*['email']
otp = request.POST.*get*['otp']


But now it gives another error,


[image: image.png]


On Tue, Jan 18, 2022 at 10:10 PM Bernard Mallala 
wrote:

>
> In your model, be sure to address defaults and required values such that
> something is passed or be user to validate.
>
> Replace
> request.POST['']
>
> With
> request.POST.get('')
>
> For example request.POST['otp']
> TO
> request.POST.get['otp']
>
>
>
> On Tuesday, January 18, 2022 at 9:00:41 AM UTC-7 bikash...@gmail.com
> wrote:
>
>> first of what did you use to generate otp. If you've used pyotp libraries
>> then you can verify otp in simple step and the documentation is good in
>> pyotp.
>>
>> On Tue, Jan 18, 2022 at 8:35 PM Leo guitar girl 
>> wrote:
>>
>>> I am following the tutorial from LearnVern.com
>>>
>>>
>>> https://www.learnvern.com/python-tutorial-django/project-implementation-part2
>>>
>>> I have followed ditto as taught in the tutorial but the trainer has no
>>> issue and I have this issue.
>>>
>>> I am sharing the views.py code also
>>>
>>> from django.shortcuts import render
>>> from .models import *
>>> from random import randint
>>>
>>>
>>> # Create your views here.
>>>
>>> def Index(request):
>>> return render(request, 'myapp/index.html')
>>>
>>>
>>> def SignupPage(request):
>>> return render(request, 'myapp/signup.html')
>>>
>>>
>>> def RegisterUser(request):
>>> if request.POST['role'] == "Candidate":
>>> role = request.POST['role']  # Master Table Field
>>> fname = request.POST['fname']  # Candidate Table Field
>>> lname = request.POST['lname']  # Candidate Table Field
>>> email = request.POST['email']  # Master Table Field
>>> password = request.POST['password']  # Master Table Field
>>> cpassword = request.POST['cpassword']
>>>
>>> user = UserMaster.objects.filter(email=email)
>>>
>>> if user:
>>> message = "User already Exist"
>>> return render(request, "myapp/signup.html", {'msg': message})
>>> else:
>>> if password == cpassword:
>>> otp = randint(10, 99)
>>> newuser = UserMaster.objects.create(role=role, otp=otp, 
>>> email=email, password=password)
>>> newcand = Candidate.objects.create(user_id=newuser, 
>>> firstname=fname, lastname=lname)
>>> return render(request, "myapp/otpverify.html", {'email': 
>>> email})
>>> else:
>>> print("Company Registration")
>>>
>>>
>>> def OTPpage(request):
>>> return render(request, "myapp/otpverify.html")
>>>
>>>
>>> def OTPverify(request):
>>> if request.method == 'POST':
>>> email = request.POST['email']
>>> otp = request.POST['otp']
>>>
>>> user = UserMaster.objects.get(email=email)
>>>
>>> if user:
>>> if user.otp == otp:
>>> message = "OTP Verified Successfully!"
>>> return render(request, "myapp/login.html", {'msg': message})
>>> else:
>>> message = "OTP is incorrect"
>>> return render(request, "myapp/otpverify.html", {'msg': 
>>> message})
>>> else:
>>> return render(request, "myapp/signup.html")
>>>
>>>
>>> On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
>>> wrote:
>>>
 On 18/01/2022 04.31, Leo guitar girl wrote:
 > Oh, I apologize. I had pasted the error code here don't know why it
 was
 > not sent.
 > Actually, I am trying to create a job portal by seeing a tutorial.
 Now I
 > am at the step of verifying OTP. OTP is generated successfully in the
 > database. But when I enter it to the textbox and submit, it shows
 this error
 >

 Which tutorial are you following?

 What's in the views.py file that is causing the error?

 Kind regards,

 Kasper Laudrup

 --
 You received this message because you are subscribed to a topic in the
 Google Groups "Django users" group.
 To unsubscribe from this topic, visit
 https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
 To unsubscribe from this group and all its topics, send an email to
 django-users...@googlegroups.com.
 To view this discussion on the web visit
 https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk
 .

>>> --
>>>
>> You received this message because you are subscribed to the Google Groups
>>> "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to django-users...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CAN6g9JZG-4VbKFDOJtWg3rMWY4i23Gh%2Bga3PfKxYBmVMR38ayw%40mail.gmail.com
>>> 

Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Jasur Suyunov
Hello my friend

Sesh, 18-yan, 2022, 7:50 TK Leo guitar girl :

> I am following the tutorial from LearnVern.com
>
>
> https://www.learnvern.com/python-tutorial-django/project-implementation-part2
>
> I have followed ditto as taught in the tutorial but the trainer has no
> issue and I have this issue.
>
> I am sharing the views.py code also
>
> from django.shortcuts import render
> from .models import *
> from random import randint
>
>
> # Create your views here.
>
> def Index(request):
> return render(request, 'myapp/index.html')
>
>
> def SignupPage(request):
> return render(request, 'myapp/signup.html')
>
>
> def RegisterUser(request):
> if request.POST['role'] == "Candidate":
> role = request.POST['role']  # Master Table Field
> fname = request.POST['fname']  # Candidate Table Field
> lname = request.POST['lname']  # Candidate Table Field
> email = request.POST['email']  # Master Table Field
> password = request.POST['password']  # Master Table Field
> cpassword = request.POST['cpassword']
>
> user = UserMaster.objects.filter(email=email)
>
> if user:
> message = "User already Exist"
> return render(request, "myapp/signup.html", {'msg': message})
> else:
> if password == cpassword:
> otp = randint(10, 99)
> newuser = UserMaster.objects.create(role=role, otp=otp, 
> email=email, password=password)
> newcand = Candidate.objects.create(user_id=newuser, 
> firstname=fname, lastname=lname)
> return render(request, "myapp/otpverify.html", {'email': 
> email})
> else:
> print("Company Registration")
>
>
> def OTPpage(request):
> return render(request, "myapp/otpverify.html")
>
>
> def OTPverify(request):
> if request.method == 'POST':
> email = request.POST['email']
> otp = request.POST['otp']
>
> user = UserMaster.objects.get(email=email)
>
> if user:
> if user.otp == otp:
> message = "OTP Verified Successfully!"
> return render(request, "myapp/login.html", {'msg': message})
> else:
> message = "OTP is incorrect"
> return render(request, "myapp/otpverify.html", {'msg': 
> message})
> else:
> return render(request, "myapp/signup.html")
>
>
> On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
> wrote:
>
>> On 18/01/2022 04.31, Leo guitar girl wrote:
>> > Oh, I apologize. I had pasted the error code here don't know why it was
>> > not sent.
>> > Actually, I am trying to create a job portal by seeing a tutorial. Now
>> I
>> > am at the step of verifying OTP. OTP is generated successfully in the
>> > database. But when I enter it to the textbox and submit, it shows
>> this error
>> >
>>
>> Which tutorial are you following?
>>
>> What's in the views.py file that is causing the error?
>>
>> Kind regards,
>>
>> Kasper Laudrup
>>
>> --
>> You received this message because you are subscribed to a topic in the
>> Google Groups "Django users" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAN6g9JZG-4VbKFDOJtWg3rMWY4i23Gh%2Bga3PfKxYBmVMR38ayw%40mail.gmail.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAGCNaHq%2B7u97EmsxRuMm0cviQj%3DmQFgp9cLSO398Q2hfZSb44A%40mail.gmail.com.


Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Abubakar Siddique
Hi,

Hope you are well

Did you successfully find the bug or not


here is my whatsapp number
You can contact here
923158090326

Thanks

On Tue, Jan 18, 2022 at 8:32 AM Leo guitar girl 
wrote:

> Oh, I apologize. I had pasted the error code here don't know why it was
> not sent.
> Actually, I am trying to create a job portal by seeing a tutorial. Now I
> am at the step of verifying OTP. OTP is generated successfully in the
> database. But when I enter it to the textbox and submit, it shows this error
>
> [image: image.png]
>
> *Please Note: I am gett*ing the submitted email from the database and
> showing it at the OTP verify page in a read-only field.
>
> Here is the Copy Paste view also of the error message
>
> Environment:
>
>
> Request Method: POST
> Request URL: http://127.0.0.1:8000/otp/
>
> Django Version: 4.0.1
> Python Version: 3.9.9
> Installed Applications:
> ['django.contrib.admin',
>  'django.contrib.auth',
>  'django.contrib.contenttypes',
>  'django.contrib.sessions',
>  'django.contrib.messages',
>  'django.contrib.staticfiles',
>  'myapp']
> Installed Middleware:
> ['django.middleware.security.SecurityMiddleware',
>  'django.contrib.sessions.middleware.SessionMiddleware',
>  'django.middleware.common.CommonMiddleware',
>  'django.middleware.csrf.CsrfViewMiddleware',
>  'django.contrib.auth.middleware.AuthenticationMiddleware',
>  'django.contrib.messages.middleware.MessageMiddleware',
>  'django.middleware.clickjacking.XFrameOptionsMiddleware']
>
>
>
> Traceback (most recent call last):
>   File
> "C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\utils\datastructures.py",
> line 83, in __getitem__
> list_ = super().__getitem__(key)
>
> During handling of the above exception ('email'), another exception
> occurred:
>   File
> "C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\core\handlers\exception.py",
> line 47, in inner
> response = get_response(request)
>   File
> "C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\core\handlers\base.py",
> line 181, in _get_response
> response = wrapped_callback(request, *callback_args, **callback_kwargs)
>   File "C:\Users\jarry\PycharmProjects\JobPortal\myapp\views.py", line 46,
> in OTPverify
> email = request.POST['email']
>   File
> "C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\utils\datastructures.py",
> line 85, in __getitem__
> raise MultiValueDictKeyError(key)
>
> Exception Type: MultiValueDictKeyError at /otp/
> Exception Value: 'email'
>
> *Thank You for your support. *
>
> On Mon, Jan 17, 2022 at 1:15 AM Kasper Laudrup 
> wrote:
>
>> On 16/01/2022 11.03, Leo guitar girl wrote:
>> >
>> > *This is the error I am getting at OTP verification step. Please guide
>> > me where I am wrong. *
>> > *
>>
>> No one here would have any idea what "OTP verification step" you are
>> talking about.
>>
>> You haven't written anything about what you are trying to achieve or
>> shared any relevant code so it's close to impossible for anyone to help
>> you.
>>
>> So your first step would be to learn how to ask questions in general.
>> Consider reading something like this:
>>
>> http://www.catb.org/~esr/faqs/smart-questions.html
>>
>> Kind regards,
>>
>> Kasper Laudrup
>>
>> --
>> You received this message because you are subscribed to a topic in the
>> Google Groups "Django users" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/60ef1f71-85b3-0fad-d9b8-ad48139fb01e%40stacktrace.dk
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAN6g9JZ26XSF%3DtQp6%2BXrwx1Av0JV%2BJsUsfkga1mnFtiBumUu8A%40mail.gmail.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAL2GMxSDKLUUgEEBvW3Td0YhqEeO

Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Bernard Mallala

In your model, be sure to address defaults and required values such that 
something is passed or be user to validate.

Replace 
request.POST['']

With
request.POST.get('')

For example request.POST['otp'] 
TO 
request.POST.get['otp'] 



On Tuesday, January 18, 2022 at 9:00:41 AM UTC-7 bikash...@gmail.com wrote:

> first of what did you use to generate otp. If you've used pyotp libraries 
> then you can verify otp in simple step and the documentation is good in 
> pyotp.
>
> On Tue, Jan 18, 2022 at 8:35 PM Leo guitar girl  
> wrote:
>
>> I am following the tutorial from LearnVern.com 
>>
>>
>> https://www.learnvern.com/python-tutorial-django/project-implementation-part2
>>
>> I have followed ditto as taught in the tutorial but the trainer has no 
>> issue and I have this issue. 
>>
>> I am sharing the views.py code also 
>>
>> from django.shortcuts import render
>> from .models import *
>> from random import randint
>>
>>
>> # Create your views here.
>>
>> def Index(request):
>> return render(request, 'myapp/index.html')
>>
>>
>> def SignupPage(request):
>> return render(request, 'myapp/signup.html')
>>
>>
>> def RegisterUser(request):
>> if request.POST['role'] == "Candidate":
>> role = request.POST['role']  # Master Table Field
>> fname = request.POST['fname']  # Candidate Table Field
>> lname = request.POST['lname']  # Candidate Table Field
>> email = request.POST['email']  # Master Table Field
>> password = request.POST['password']  # Master Table Field
>> cpassword = request.POST['cpassword']
>>
>> user = UserMaster.objects.filter(email=email)
>>
>> if user:
>> message = "User already Exist"
>> return render(request, "myapp/signup.html", {'msg': message})
>> else:
>> if password == cpassword:
>> otp = randint(10, 99)
>> newuser = UserMaster.objects.create(role=role, otp=otp, 
>> email=email, password=password)
>> newcand = Candidate.objects.create(user_id=newuser, 
>> firstname=fname, lastname=lname)
>> return render(request, "myapp/otpverify.html", {'email': 
>> email})
>> else:
>> print("Company Registration")
>>
>>
>> def OTPpage(request):
>> return render(request, "myapp/otpverify.html")
>>
>>
>> def OTPverify(request):
>> if request.method == 'POST':
>> email = request.POST['email']
>> otp = request.POST['otp']
>>
>> user = UserMaster.objects.get(email=email)
>>
>> if user:
>> if user.otp == otp:
>> message = "OTP Verified Successfully!"
>> return render(request, "myapp/login.html", {'msg': message})
>> else:
>> message = "OTP is incorrect"
>> return render(request, "myapp/otpverify.html", {'msg': 
>> message})
>> else:
>> return render(request, "myapp/signup.html")
>>
>>
>> On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup  
>> wrote:
>>
>>> On 18/01/2022 04.31, Leo guitar girl wrote:
>>> > Oh, I apologize. I had pasted the error code here don't know why it 
>>> was 
>>> > not sent.
>>> > Actually, I am trying to create a job portal by seeing a tutorial. Now 
>>> I 
>>> > am at the step of verifying OTP. OTP is generated successfully in the 
>>> > database. But when I enter it to the textbox and submit, it shows 
>>> this error
>>> > 
>>>
>>> Which tutorial are you following?
>>>
>>> What's in the views.py file that is causing the error?
>>>
>>> Kind regards,
>>>
>>> Kasper Laudrup
>>>
>>> -- 
>>> You received this message because you are subscribed to a topic in the 
>>> Google Groups "Django users" group.
>>> To unsubscribe from this topic, visit 
>>> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to 
>>> django-users...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk
>>> .
>>>
>> -- 
>>
> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to django-users...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/CAN6g9JZG-4VbKFDOJtWg3rMWY4i23Gh%2Bga3PfKxYBmVMR38ayw%40mail.gmail.com
>>  
>> 
>> .
>>
>
>
> -- 
> Best Regards,
> Bikash Poudel
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on th

Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Vkash Poudel
first of what did you use to generate otp. If you've used pyotp libraries
then you can verify otp in simple step and the documentation is good in
pyotp.

On Tue, Jan 18, 2022 at 8:35 PM Leo guitar girl 
wrote:

> I am following the tutorial from LearnVern.com
>
>
> https://www.learnvern.com/python-tutorial-django/project-implementation-part2
>
> I have followed ditto as taught in the tutorial but the trainer has no
> issue and I have this issue.
>
> I am sharing the views.py code also
>
> from django.shortcuts import render
> from .models import *
> from random import randint
>
>
> # Create your views here.
>
> def Index(request):
> return render(request, 'myapp/index.html')
>
>
> def SignupPage(request):
> return render(request, 'myapp/signup.html')
>
>
> def RegisterUser(request):
> if request.POST['role'] == "Candidate":
> role = request.POST['role']  # Master Table Field
> fname = request.POST['fname']  # Candidate Table Field
> lname = request.POST['lname']  # Candidate Table Field
> email = request.POST['email']  # Master Table Field
> password = request.POST['password']  # Master Table Field
> cpassword = request.POST['cpassword']
>
> user = UserMaster.objects.filter(email=email)
>
> if user:
> message = "User already Exist"
> return render(request, "myapp/signup.html", {'msg': message})
> else:
> if password == cpassword:
> otp = randint(10, 99)
> newuser = UserMaster.objects.create(role=role, otp=otp, 
> email=email, password=password)
> newcand = Candidate.objects.create(user_id=newuser, 
> firstname=fname, lastname=lname)
> return render(request, "myapp/otpverify.html", {'email': 
> email})
> else:
> print("Company Registration")
>
>
> def OTPpage(request):
> return render(request, "myapp/otpverify.html")
>
>
> def OTPverify(request):
> if request.method == 'POST':
> email = request.POST['email']
> otp = request.POST['otp']
>
> user = UserMaster.objects.get(email=email)
>
> if user:
> if user.otp == otp:
> message = "OTP Verified Successfully!"
> return render(request, "myapp/login.html", {'msg': message})
> else:
> message = "OTP is incorrect"
> return render(request, "myapp/otpverify.html", {'msg': 
> message})
> else:
> return render(request, "myapp/signup.html")
>
>
> On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
> wrote:
>
>> On 18/01/2022 04.31, Leo guitar girl wrote:
>> > Oh, I apologize. I had pasted the error code here don't know why it was
>> > not sent.
>> > Actually, I am trying to create a job portal by seeing a tutorial. Now
>> I
>> > am at the step of verifying OTP. OTP is generated successfully in the
>> > database. But when I enter it to the textbox and submit, it shows
>> this error
>> >
>>
>> Which tutorial are you following?
>>
>> What's in the views.py file that is causing the error?
>>
>> Kind regards,
>>
>> Kasper Laudrup
>>
>> --
>> You received this message because you are subscribed to a topic in the
>> Google Groups "Django users" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAN6g9JZG-4VbKFDOJtWg3rMWY4i23Gh%2Bga3PfKxYBmVMR38ayw%40mail.gmail.com
> 
> .
>


-- 
Best Regards,
Bikash Poudel

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAE0sOGxjPxmRpd2CcucoeSTFuAqa1U_CBU2N7RTxZ7GLH-kTLA%40mail.gmail.com.


Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Leo guitar girl
I am following the tutorial from LearnVern.com

https://www.learnvern.com/python-tutorial-django/project-implementation-part2

I have followed ditto as taught in the tutorial but the trainer has no
issue and I have this issue.

I am sharing the views.py code also

from django.shortcuts import render
from .models import *
from random import randint


# Create your views here.

def Index(request):
return render(request, 'myapp/index.html')


def SignupPage(request):
return render(request, 'myapp/signup.html')


def RegisterUser(request):
if request.POST['role'] == "Candidate":
role = request.POST['role']  # Master Table Field
fname = request.POST['fname']  # Candidate Table Field
lname = request.POST['lname']  # Candidate Table Field
email = request.POST['email']  # Master Table Field
password = request.POST['password']  # Master Table Field
cpassword = request.POST['cpassword']

user = UserMaster.objects.filter(email=email)

if user:
message = "User already Exist"
return render(request, "myapp/signup.html", {'msg': message})
else:
if password == cpassword:
otp = randint(10, 99)
newuser = UserMaster.objects.create(role=role,
otp=otp, email=email, password=password)
newcand = Candidate.objects.create(user_id=newuser,
firstname=fname, lastname=lname)
return render(request, "myapp/otpverify.html", {'email': email})
else:
print("Company Registration")


def OTPpage(request):
return render(request, "myapp/otpverify.html")


def OTPverify(request):
if request.method == 'POST':
email = request.POST['email']
otp = request.POST['otp']

user = UserMaster.objects.get(email=email)

if user:
if user.otp == otp:
message = "OTP Verified Successfully!"
return render(request, "myapp/login.html", {'msg': message})
else:
message = "OTP is incorrect"
return render(request, "myapp/otpverify.html", {'msg': message})
else:
return render(request, "myapp/signup.html")


On Tue, Jan 18, 2022 at 3:21 PM Kasper Laudrup 
wrote:

> On 18/01/2022 04.31, Leo guitar girl wrote:
> > Oh, I apologize. I had pasted the error code here don't know why it was
> > not sent.
> > Actually, I am trying to create a job portal by seeing a tutorial. Now I
> > am at the step of verifying OTP. OTP is generated successfully in the
> > database. But when I enter it to the textbox and submit, it shows
> this error
> >
>
> Which tutorial are you following?
>
> What's in the views.py file that is causing the error?
>
> Kind regards,
>
> Kasper Laudrup
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/P1-fQLDoncc/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAN6g9JZG-4VbKFDOJtWg3rMWY4i23Gh%2Bga3PfKxYBmVMR38ayw%40mail.gmail.com.


Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-18 Thread Kasper Laudrup

On 18/01/2022 04.31, Leo guitar girl wrote:
Oh, I apologize. I had pasted the error code here don't know why it was 
not sent.
Actually, I am trying to create a job portal by seeing a tutorial. Now I 
am at the step of verifying OTP. OTP is generated successfully in the 
database. But when I enter it to the textbox and submit, it shows thisĀ error




Which tutorial are you following?

What's in the views.py file that is causing the error?

Kind regards,

Kasper Laudrup

--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/df6cb70c-d5a5-1f12-a832-ac5b46901fc4%40stacktrace.dk.


OpenPGP_0xE5D9CAC64AAA55EB.asc
Description: OpenPGP public key


OpenPGP_signature
Description: OpenPGP digital signature


Re: Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-16 Thread Kasper Laudrup

On 16/01/2022 11.03, Leo guitar girl wrote:


*This is the error I am getting at OTP verification step. Please guide 
me where I am wrong. *

*


No one here would have any idea what "OTP verification step" you are 
talking about.


You haven't written anything about what you are trying to achieve or 
shared any relevant code so it's close to impossible for anyone to help you.


So your first step would be to learn how to ask questions in general. 
Consider reading something like this:


http://www.catb.org/~esr/faqs/smart-questions.html

Kind regards,

Kasper Laudrup

--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/60ef1f71-85b3-0fad-d9b8-ad48139fb01e%40stacktrace.dk.


OpenPGP_0xE5D9CAC64AAA55EB.asc
Description: OpenPGP public key


OpenPGP_signature
Description: OpenPGP digital signature


Hi, I am learning Django, I am stuck at one place and can't over come after many days

2022-01-16 Thread Leo guitar girl

Environment:


Request Method: GET
Request URL: http://127.0.0.1:8000/otp/

Django Version: 4.0.1
Python Version: 3.9.9
Installed Applications:
['django.contrib.admin',
 'django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.messages',
 'django.contrib.staticfiles',
 'myapp']
Installed Middleware:
['django.middleware.security.SecurityMiddleware',
 'django.contrib.sessions.middleware.SessionMiddleware',
 'django.middleware.common.CommonMiddleware',
 'django.middleware.csrf.CsrfViewMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.contrib.messages.middleware.MessageMiddleware',
 'django.middleware.clickjacking.XFrameOptionsMiddleware']



Traceback (most recent call last):
  File 
"C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\utils\datastructures.py",
 
line 83, in __getitem__
list_ = super().__getitem__(key)

During handling of the above exception ('email'), another exception 
occurred:
  File 
"C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\core\handlers\exception.py",
 
line 47, in inner
response = get_response(request)
  File 
"C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\core\handlers\base.py",
 
line 181, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "C:\Users\jarry\PycharmProjects\JobPortal\myapp\views.py", line 45, 
in OTPverify
email = request.POST['email']
  File 
"C:\Users\jarry\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\django\utils\datastructures.py",
 
line 85, in __getitem__
raise MultiValueDictKeyError(key)

Exception Type: MultiValueDictKeyError at /otp/
Exception Value: 'email'


*This is the error I am getting at OTP verification step. Please guide me 
where I am wrong. *

*Thank You so much*

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/fa8ae7b5-e589-45b2-80f3-ae52238eab52n%40googlegroups.com.