# django.core.exceptions.ImproperlyConfigured: 未启用contenttypes框架。

- **ID:** `python/django-content-type-error`
- **领域:** python
- **类别:** config_error
- **验证级别:** ai_generated
- **修复率:** 80%

## 根因

从INSTALLED_APPS中移除了'django.contrib.contenttypes'，但auth和admin需要它。

## 版本兼容性

| 版本 | 状态 | 引入 | 弃用 |
|------|------|------|------|
| 3.x | active | — | — |

## 解决方案

1. **** (95% 成功率)
   ```
   Add 'django.contrib.contenttypes' back to INSTALLED_APPS and run migrations.
   ```
2. **** (90% 成功率)
   ```
   Ensure contenttypes is included before auth in INSTALLED_APPS.
   ```

## 无效尝试

- **** — Breaks authentication and admin functionality. (90% 失败率)
- **** — May cause migration errors if tables are missing. (80% 失败率)
