Opened 7 years ago
Last modified 7 years ago
#29796 closed Cleanup/optimization
Add a system check error if the prefix in the STATICFILES_DIRS ends with slash — at Version 1
| Reported by: | Paweł Kołodziej | Owned by: | nobody |
|---|---|---|---|
| Component: | contrib.staticfiles | Version: | dev |
| Severity: | Normal | Keywords: | |
| Cc: | Triage Stage: | Accepted | |
| Has patch: | yes | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description (last modified by )
With following config:
STATICFILES_DIRS=[ ('front/', os.path.join(BASE_DIR, 'front/build')) ]
files from 'front/build' are collected by 'manage.py collectstatic' but no served by 'runserver'.
The problem is caused by trailing slash in prefix ('front/' instead of 'front').
My first solution was to normalize the prefix, but it was suggested that it's better to report error.
Change History (1)
comment:1 by , 7 years ago
| Description: | modified (diff) |
|---|---|
| Summary: | Report error if the prefix in the STATICFILES_DIRS ends with slash → Add a system check error if the prefix in the STATICFILES_DIRS ends with slash |
| Triage Stage: | Unreviewed → Accepted |
| Type: | Uncategorized → Cleanup/optimization |
Note:
See TracTickets
for help on using tickets.