#24336: static server should skip for protocol-relative STATIC_URL
------------------------------+--------------------
     Reporter:  Tuttle        |      Owner:  nobody
         Type:  Bug           |     Status:  new
    Component:  Core (Other)  |    Version:  master
     Severity:  Normal        |   Keywords:
 Triage Stage:  Unreviewed    |  Has patch:  0
Easy pickings:  1             |      UI/UX:  0
------------------------------+--------------------
 As per http://stackoverflow.com/questions/550038/is-it-valid-to-replace-
 http-with-in-a-script-src-http and the spread of http/https websites it
 appears to be legitimate to have STATIC_URL and MEDIA_URL starting with
 `//` leading to a different domain under my control, but keeping the
 protocol. Hence this check

 {{{
     # No-op if not in debug mode or an non-local prefix
     if not settings.DEBUG or (prefix and '://' in prefix):
         return []
 }}}

 in `django.conf.urls.static.static` will not match and does not turn off
 the static server as it should.

 I guess `://` should at least be changed to `//`.

--
Ticket URL: <https://code.djangoproject.com/ticket/24336>
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/049.a99be02b34f6798e2c89145f45f7dcdf%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to