# django.core.exceptions.ImproperlyConfigured: The URL pattern 'myapp/' does not have a trailing slash.

- **ID:** `python/django-redirect-without-trailing-slash`
- **Domain:** python
- **Category:** config_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

URL patterns defined without trailing slash, but Django's APPEND_SLASH setting expects slashes.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 3.x | active | — | — |

## Workarounds

1. **** (95% success)
   ```
   Ensure all URL patterns end with a slash: path('myapp/', views.my_view).
   ```
2. **** (90% success)
   ```
   Use re_path with regex that allows optional trailing slash.
   ```

## Dead Ends

- **** — Disables automatic slash appending, may break expected URL behavior and cause 404s. (70% fail)
- **** — Complex and unnecessary; best to define URLs consistently with slashes. (60% fail)
