Formulaire de formulaire requis dans les vues Django

if request.method == 'POST':
      form = LabelingForm(request.POST)

      required = 'C' in request.POST
      form.fields['First_choice'].required = required
      form.fields['Second_choice'].required = required

      if form.is_valid():
          ...
Mad developer