                  fields = ['array_field', 'array_field_with_blank']
  
          expected = dedent("""
              TestSerializer():
                  array_field = ListField(allow_empty=False, child=CharField(label='Array field'%s))
                  array_field_with_blank = ListField(child=CharField(label='Array field with blank'%s), required=False)
          """ % (validators, validators))
 
</s> remove                 array_field = ListField(allow_empty=False, child=CharField(label='Array field', validators=[<django.core.validators.MaxLengthValidator object>]))
                array_field_with_blank = ListField(child=CharField(label='Array field with blank', validators=[<django.core.validators.MaxLengthValidator object>]), required=False)
        """)
 </s> add                 array_field = ListField(allow_empty=False, child=CharField(label='Array field'%s))
                array_field_with_blank = ListField(child=CharField(label='Array field with blank'%s), required=False)
        """ % (validators, validators)) </s> remove         django40: Django>=4.0,<5.0
 </s> add         django40: Django>=4.0,<4.1
        django41: Django>=4.1a1,<4.2 </s> remove        {py38,py39,py310}-{django40,djangomain},
 </s> add        {py38,py39,py310}-{django40,django41,djangomain},
        validators = ""
        if django.VERSION < (4, 1):
            validators = ", validators=[<django.core.validators.MaxLengthValidator object>]"
                  fields = ['array_field', 'array_field_with_blank']
  
        validators = ""
        if django.VERSION < (4, 1):
            validators = ", validators=[<django.core.validators.MaxLengthValidator object>]"
          expected = dedent("""
              TestSerializer():
                  array_field = ListField(allow_empty=False, child=CharField(label='Array field'%s))
                  array_field_with_blank = ListField(child=CharField(label='Array field with blank'%s), required=False)
          """ % (validators, validators))
keep add keep keep keep keep keep
 Confirmed support for Django 4.1. (#8498) 
tests/test_model_serializer.py