forms.py (e.g. admin.py ) is just the convention django uses. This is considered best practice, but not a strict requirement. There is nothing special or exotic in these files.
forms.py - where django documentation recommends placing all your forms; make your code easy to repair. Also, since its convention is mentioned in the documentation, it helps when you collaborate with others, because that is where others will look for your code related to forms.
Think of it as index.html . There is no rule indicating that this file should be called index.html , but it is an agreement that has been built over time.
You can use all form classes in your views.py and nothing will break. Now, if you do not use forms at all and still process the GET and POST data manually, you should stop it immediately; especially if it's more than a search query string.
The only file that is absolutely necessary is models.py .
source share