#26329: StaticFilesStorage permits leading slash, CachedStaticFilesStorage
doesn't
-------------------------------+--------------------
Reporter: SeanHayes | Owner: nobody
Type: Bug | Status: new
Component: Uncategorized | Version: 1.8
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------
I got the following email from our staging server:
{{{
The joined path (/images/no-image.jpg) is located outside of the base path
component (/full-path/collected-static)
}}}
Someone was using the following template tag:
{{{
{% static "/images/no-image.jpg" as no_image_url %}
}}}
I checked to see why our tests didn't raise the same error, and it turns
out it only happens with CachedStaticFilesStorage (and likely the other
manifest storages), StaticFilesStorage and FileSystemStorage seem to just
ignore this error.
Since CachedStaticFilesStorage shouldn't be used during testing, I think
the parent classes should raise the same error.
--
Ticket URL: <https://code.djangoproject.com/ticket/26329>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/052.9bcc8f7b56580d6c5f59415ef292e3d6%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.