I have a Django app and trying to understand the logic on how to read docs correctly in order to e.g. create a Charfield object.
So here is my model:
from django.db import models class Person(models.Model): f_name = models.CharField() . . . . . . If I run the app I get the error:
Charfields must define a 'max_length' attribute
I get that I need to do:
f_name = models.CharField(max_length=40)
But why? when I read the code for Charfield it's not there, so I read the code for its superclass Field but I don't see where max_length is set to be compulsory!
Please assist (new to oop)