Using multiple basic patterns is the solution I've seen in several teams. For example, you can simply add an additional base template called "base_with_form.html". Templates that need form extend this basic template.
One thing that helped me was to think about decomposing the template directories in the same way as Python packages. I usually use base.html for each directory (ala init .py), even if it's just a placeholder. Each base file extends the base file in the parent directory. Additional style specializations for several templates in the same directory are done by adding copies of the local base.html with the required changes.
Example:
templates/ base.html index.html (extends "base.html") accounts/ base.html (extends "base.html") affiliate_base.html (extends "base.html") my_account.html (extends "accounts/base.html") affiliate_dashboard.html (extends "accounts/affiliate_base.html") vips/ base.html (extend "accounts/base.html") vip_lounge.html (extends "accounts/vips/base.html")
source share