#17865: CachedStaticFilesStorage css rewriter should strip whitespaces from urls
-------------------------------------+------------------------
Reporter: kmike | Owner: nobody
Type: Bug | Status: new
Component: contrib.staticfiles | Version: 1.4-beta-1
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+------------------------
I have this rule in one of css files (note the extra whitespace in the
url):
{{{
.b-error-page {
background: url(../img/bg-error-page.png ) center 0 no-repeat;
}
}}}
Browsers handle this fine, collectstatic raises an exception if
CachedStaticFilesStorage is used:
{{{
ValueError: The file 'img/bg-error-page.png ' could not be found with
<django.contrib.staticfiles.storage.CachedStaticFilesStorage object at
0x2ee2350>.
}}}
I think css rewriter should just strip whitespaces in such cases.
Not sure if this is relevant, but anyway:
http://www.ietf.org/rfc/rfc3986 , Appendix C: "For robustness, software
that accepts user-typed URI should attempt to recognize and strip both
delimiters and embedded whitespace."
--
Ticket URL: <https://code.djangoproject.com/ticket/17865>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en.