403 g = marks_for_student.send(
404 AddSectionMarks, scsddc=req_scsddc, coursesection=section, sectionmarks=sec_marks, option='create')
405 print(g)
406 except IntegrityError as e:407
408 # data = SectionMarksSerializer(
409 # sec_att2, context={'request': request}).data
332 req_scsddc = request.POST['scsddc']
333 slot = request.POST['slot']
334 section = request.POST['scsddc'].split('_')[0]
335 course_code = request.POST['course_code']336 if(slot == '' or slot == 'null' or req_scsddc == '' or section == ''):
337 return JsonResponse({'message': 'Invalid Form Inputs', 'condition': False, }, status=422)
338
198 from pprint import pprint
199 pprint(offered_courses_to_student)
200
201 except Semester.DoesNotExist as e:202 return JsonResponse({'message': 'Invalid Semester. Contact Adminstration.', 'condition': False, 'error_raised': True}, status=401)
203
204 except OfferedCourses.DoesNotExist as e:
392 challan, created = FeeChallan.objects.get_or_create(
393 student=student, semester=semester)
394 if created == True:
395 transcript = Transcript.objects.get_or_create(396 student=student, semester=Semester.objects.get(current_semester=True))[0]
397 challan.coActivity_charges = semester.co_circular_fee
398 challan.due_date = EndDate
508 print('Received Signal For Creation Attendance of Day for student')
509 SCSDDC_temp = str(kwargs['scsddc'])
510 section_attendance = kwargs['sectionattendance']
511 section = kwargs['coursesection']512 scsddc_dict = split_scsddc(SCSDDC_temp)
513 print(Fore.RED + scsddc_dict['section'])
514 print(scsddc_dict['course_code'])
An unused variable takes up space in the code, and can lead to confusion, and it should be removed. If this variable is necessary, name the variable _
to indicate that it will be unused, or start the name with unused
or _unused
.
def update():
for i in range(10): # Usused variable `i`
time.sleep(0.01)
display_result()
def update():
for _ in range(10):
time.sleep(0.01)
display_result()